]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - mm/memcontrol.c
memcg, thp: do not invoke oom killer on thp charges
[linux.git] / mm / memcontrol.c
index 9ec024b862aca01cb32d302584e6b110d11107a7..6b4f5c0a8eefdf49539532517d08c19e0dfef276 100644 (file)
@@ -1485,7 +1485,7 @@ static void memcg_oom_recover(struct mem_cgroup *memcg)
 
 static void mem_cgroup_oom(struct mem_cgroup *memcg, gfp_t mask, int order)
 {
-       if (!current->memcg_may_oom)
+       if (!current->memcg_may_oom || order > PAGE_ALLOC_COSTLY_ORDER)
                return;
        /*
         * We are in the middle of the charge context here, so we