Subject: + memcg-use-css_get-put-when-charging-uncharging-kmem-fix-fix.patch added to -mm tree To: lizefan@xxxxxxxxxx,fengguang.wu@xxxxxxxxx,mhocko@xxxxxxx,sedat.dilek@xxxxxxxxx,sfr@xxxxxxxxxxxxxxxx From: akpm@xxxxxxxxxxxxxxxxxxxx Date: Wed, 03 Jul 2013 11:05:32 -0700 The patch titled Subject: memcg: fix build error if CONFIG_MEMCG_KMEM=n has been added to the -mm tree. Its filename is memcg-use-css_get-put-when-charging-uncharging-kmem-fix-fix.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/SubmitChecklist when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Li Zefan <lizefan@xxxxxxxxxx> Subject: memcg: fix build error if CONFIG_MEMCG_KMEM=n Fix this build error: mm/built-in.o: In function `mem_cgroup_css_free': memcontrol.c:(.text+0x5caa6): undefined reference to 'mem_cgroup_sockets_destroy' Maybe it's better to add memcg_destroy_kmem(), to pair with memcg_init_kmem(). This patch can be folded into "memcg: use css_get/put when charging/uncharging kmem". Rename the patch as it is a follow-up for the mmotm tree: "memcg-use-css_get-put-when-charging-uncharging-kmem-fix-2.patch" See [1] for the original patch and follow the discussion in [2]. [1] http://marc.info/?l=linux-mm&m=137285590123430&w=2 [2] http://marc.info/?t=137285378500005&r=1&w=2 Reported-by: Fengguang Wu <fengguang.wu@xxxxxxxxx> Reported-by: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx> Reported-by: Sedat Dilek <sedat.dilek@xxxxxxxxx> Tested-by: Sedat Dilek <sedat.dilek@xxxxxxxxx> Acked-by: Michal Hocko <mhocko@xxxxxxx> Signed-off-by: Li Zefan <lizefan@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/memcontrol.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff -puN mm/memcontrol.c~memcg-use-css_get-put-when-charging-uncharging-kmem-fix-fix mm/memcontrol.c --- a/mm/memcontrol.c~memcg-use-css_get-put-when-charging-uncharging-kmem-fix-fix +++ a/mm/memcontrol.c @@ -5916,6 +5916,11 @@ static int memcg_init_kmem(struct mem_cg return mem_cgroup_sockets_init(memcg, ss); } +static void memcg_destroy_kmem(struct mem_cgroup *memcg) +{ + mem_cgroup_sockets_destroy(memcg); +} + static void kmem_cgroup_css_offline(struct mem_cgroup *memcg) { if (!memcg_kmem_is_active(memcg)) @@ -5955,6 +5960,10 @@ static int memcg_init_kmem(struct mem_cg return 0; } +static void memcg_destroy_kmem(struct mem_cgroup *memcg) +{ +} + static void kmem_cgroup_css_offline(struct mem_cgroup *memcg) { } @@ -6399,8 +6408,7 @@ static void mem_cgroup_css_free(struct c { struct mem_cgroup *memcg = mem_cgroup_from_cont(cont); - mem_cgroup_sockets_destroy(memcg); - + memcg_destroy_kmem(memcg); mem_cgroup_put(memcg); } _ Patches currently in -mm which might be from lizefan@xxxxxxxxxx are linux-next.patch memcg-update-todo-list-in-documentation.patch revert-memcg-avoid-dangling-reference-count-in-creation-failure.patch memcg-kmem-fix-reference-count-handling-on-the-error-path.patch memcg-use-css_get-in-sock_update_memcg.patch memcg-dont-use-mem_cgroup_get-when-creating-a-kmemcg-cache.patch memcg-use-css_get-put-when-charging-uncharging-kmem.patch memcg-use-css_get-put-when-charging-uncharging-kmem-fix.patch memcg-use-css_get-put-when-charging-uncharging-kmem-fix-fix.patch memcg-use-css_get-put-for-swap-memcg.patch memcg-dont-need-to-get-a-reference-to-the-parent.patch memcg-kill-memcg-refcnt.patch memcg-dont-need-to-free-memcg-via-rcu-or-workqueue.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html