Skip to content

Commit

Permalink
mm: memcg/slab: remove unused argument by charge_slab_page()
Browse files Browse the repository at this point in the history
charge_slab_page() is not using the gfp argument anymore,
remove it.

Signed-off-by: Roman Gushchin <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Reviewed-by: Shakeel Butt <[email protected]>
Acked-by: Vlastimil Babka <[email protected]>
Cc: Christoph Lameter <[email protected]>
Cc: Pekka Enberg <[email protected]>
Cc: David Rientjes <[email protected]>
Cc: Joonsoo Kim <[email protected]>
Cc: Johannes Weiner <[email protected]>
Cc: Michal Hocko <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
rgushchin authored and torvalds committed Aug 7, 2020
1 parent 991e767 commit 8495048
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion mm/slab.c
Original file line number Diff line number Diff line change
Expand Up @@ -1379,7 +1379,7 @@ static struct page *kmem_getpages(struct kmem_cache *cachep, gfp_t flags,
return NULL;
}

charge_slab_page(page, flags, cachep->gfporder, cachep);
charge_slab_page(page, cachep->gfporder, cachep);
__SetPageSlab(page);
/* Record if ALLOC_NO_WATERMARKS was set when allocating the slab */
if (sk_memalloc_socks() && page_is_pfmemalloc(page))
Expand Down
3 changes: 1 addition & 2 deletions mm/slab.h
Original file line number Diff line number Diff line change
Expand Up @@ -423,8 +423,7 @@ static inline struct kmem_cache *virt_to_cache(const void *obj)
return page->slab_cache;
}

static __always_inline void charge_slab_page(struct page *page,
gfp_t gfp, int order,
static __always_inline void charge_slab_page(struct page *page, int order,
struct kmem_cache *s)
{
mod_node_page_state(page_pgdat(page), cache_vmstat_idx(s),
Expand Down
2 changes: 1 addition & 1 deletion mm/slub.c
Original file line number Diff line number Diff line change
Expand Up @@ -1621,7 +1621,7 @@ static inline struct page *alloc_slab_page(struct kmem_cache *s,
page = __alloc_pages_node(node, flags, order);

if (page)
charge_slab_page(page, flags, order, s);
charge_slab_page(page, order, s);

return page;
}
Expand Down

0 comments on commit 8495048

Please sign in to comment.