diff options
author | James Morris <james.l.morris@oracle.com> | 2017-07-25 02:44:18 +0200 |
---|---|---|
committer | James Morris <james.l.morris@oracle.com> | 2017-07-25 02:44:18 +0200 |
commit | 53a2ebaaabc1eb8458796fec3bc1e0e80746b642 (patch) | |
tree | 9d1f9227b49392cdd2edcc01057517da4f4b09c2 /mm/slab.h | |
parent | LSM: Remove security_task_create() hook. (diff) | |
parent | Linux 4.13-rc2 (diff) | |
download | linux-53a2ebaaabc1eb8458796fec3bc1e0e80746b642.tar.xz linux-53a2ebaaabc1eb8458796fec3bc1e0e80746b642.zip |
sync to Linus v4.13-rc2 for subsystem developers to work against
Diffstat (limited to 'mm/slab.h')
-rw-r--r-- | mm/slab.h | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/mm/slab.h b/mm/slab.h index 9cfcf099709c..6885e1192ec5 100644 --- a/mm/slab.h +++ b/mm/slab.h @@ -274,22 +274,11 @@ static __always_inline int memcg_charge_slab(struct page *page, gfp_t gfp, int order, struct kmem_cache *s) { - int ret; - if (!memcg_kmem_enabled()) return 0; if (is_root_cache(s)) return 0; - - ret = memcg_kmem_charge_memcg(page, gfp, order, s->memcg_params.memcg); - if (ret) - return ret; - - memcg_kmem_update_page_stat(page, - (s->flags & SLAB_RECLAIM_ACCOUNT) ? - MEMCG_SLAB_RECLAIMABLE : MEMCG_SLAB_UNRECLAIMABLE, - 1 << order); - return 0; + return memcg_kmem_charge_memcg(page, gfp, order, s->memcg_params.memcg); } static __always_inline void memcg_uncharge_slab(struct page *page, int order, @@ -297,11 +286,6 @@ static __always_inline void memcg_uncharge_slab(struct page *page, int order, { if (!memcg_kmem_enabled()) return; - - memcg_kmem_update_page_stat(page, - (s->flags & SLAB_RECLAIM_ACCOUNT) ? - MEMCG_SLAB_RECLAIMABLE : MEMCG_SLAB_UNRECLAIMABLE, - -(1 << order)); memcg_kmem_uncharge(page, order); } |