]> git.karo-electronics.de Git - karo-tx-linux.git/commit
mm, thp: allow fallback when pte_alloc_one() fails for huge pmd
authorDavid Rientjes <rientjes@google.com>
Thu, 3 May 2012 05:43:31 +0000 (15:43 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 3 May 2012 05:46:21 +0000 (15:46 +1000)
commit51a0306afe4197ee58bcb56a0e65dc0120d46105
tree6314bc26fe56ab4fc48439bc7928d8620780e586
parent202037f73ecdf53045e435e43dbb45d6055f1912
mm, thp: allow fallback when pte_alloc_one() fails for huge pmd

The transparent hugepages feature is careful to not invoke the oom killer
when a hugepage cannot be allocated.

pte_alloc_one() failing in __do_huge_pmd_anonymous_page(), however,
currently results in VM_FAULT_OOM which invokes the pagefault oom killer
to kill a memory-hogging task.

This is unnecessary since it's possible to drop the reference to the
hugepage and fallback to allocating a small page.

Signed-off-by: David Rientjes <rientjes@google.com>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/huge_memory.c