The patch titled Subject: memcg-schedule-high-reclaim-for-remote-memcgs-on-high_work-v3 has been added to the -mm tree. Its filename is memcg-schedule-high-reclaim-for-remote-memcgs-on-high_work-v3.patch This patch should soon appear at http://ozlabs.org/~akpm/mmots/broken-out/memcg-schedule-high-reclaim-for-remote-memcgs-on-high_work-v3.patch and later at http://ozlabs.org/~akpm/mmotm/broken-out/memcg-schedule-high-reclaim-for-remote-memcgs-on-high_work-v3.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/process/submit-checklist.rst when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Shakeel Butt <shakeelb@xxxxxxxxxx> Subject: memcg-schedule-high-reclaim-for-remote-memcgs-on-high_work-v3 TIF_NOTIFY_RESUME can be set from places other than try_charge() in which case current->memcg_high_reclaim will be null. Correctly handle such scenarios. Link: http://lkml.kernel.org/r/20190110174432.82064-1-shakeelb@xxxxxxxxxx Signed-off-by: Shakeel Butt <shakeelb@xxxxxxxxxx> Cc: Johannes Weiner <hannes@xxxxxxxxxxx> Cc: Michal Hocko <mhocko@xxxxxxxx> Cc: Vladimir Davydov <vdavydov.dev@xxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- --- a/mm/memcontrol.c~memcg-schedule-high-reclaim-for-remote-memcgs-on-high_work-v3 +++ a/mm/memcontrol.c @@ -2156,15 +2156,17 @@ static void high_work_func(struct work_s void mem_cgroup_handle_over_high(void) { unsigned int nr_pages = current->memcg_nr_pages_over_high; - struct mem_cgroup *memcg; + struct mem_cgroup *memcg = current->memcg_high_reclaim; if (likely(!nr_pages)) return; - memcg = current->memcg_high_reclaim; - current->memcg_high_reclaim = NULL; + if (!memcg) + memcg = get_mem_cgroup_from_mm(current->mm); + reclaim_high(memcg, nr_pages, GFP_KERNEL); css_put(&memcg->css); + current->memcg_high_reclaim = NULL; current->memcg_nr_pages_over_high = 0; } _ Patches currently in -mm which might be from shakeelb@xxxxxxxxxx are memcg-localize-memcg_kmem_enabled-check.patch memcg-schedule-high-reclaim-for-remote-memcgs-on-high_work.patch memcg-schedule-high-reclaim-for-remote-memcgs-on-high_work-v3.patch