diff options
author | Hugh Dickins <hughd@google.com> | 2015-10-22 09:03:15 +1100 |
---|---|---|
committer | Stephen Rothwell <sfr@canb.auug.org.au> | 2015-10-22 09:03:15 +1100 |
commit | 13d722ce69aa88d4c918d0896b55fa40f1ddda17 (patch) | |
tree | 6363f833779c5b7ac00af1332994a249af11271e /include | |
parent | 8803dd9908b1be287fc460e56fa94cd5b4c05305 (diff) |
memcg-simplify-and-inline-__mem_cgroup_from_kmem-fix-2
move mem_cgroup_from_kmem into list_lru.c
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Vladimir Davydov <vdavydov@virtuozzo.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/memcontrol.h | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/include/linux/memcontrol.h b/include/linux/memcontrol.h index e46d8fe9110f..72d7472da9cf 100644 --- a/include/linux/memcontrol.h +++ b/include/linux/memcontrol.h @@ -826,16 +826,6 @@ static __always_inline void memcg_kmem_put_cache(struct kmem_cache *cachep) if (memcg_kmem_enabled()) __memcg_kmem_put_cache(cachep); } - -static __always_inline struct mem_cgroup *mem_cgroup_from_kmem(void *ptr) -{ - struct page *page; - - if (!memcg_kmem_enabled()) - return NULL; - page = virt_to_head_page(ptr); - return page->mem_cgroup; -} #else #define for_each_memcg_cache_index(_idx) \ for (; NULL; ) @@ -881,11 +871,5 @@ memcg_kmem_get_cache(struct kmem_cache *cachep, gfp_t gfp) static inline void memcg_kmem_put_cache(struct kmem_cache *cachep) { } - -static inline struct mem_cgroup *mem_cgroup_from_kmem(void *ptr) -{ - return NULL; -} #endif /* CONFIG_MEMCG_KMEM */ #endif /* _LINUX_MEMCONTROL_H */ - |