Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Documentation: correct overcommit caveat in hugetlbpage.txt

As shown by Gurudas Pai recently, we can put hugepages into the surplus
state (by echo 0 > /proc/sys/vm/nr_hugepages), even when
/proc/sys/vm/nr_overcommit_hugepages is 0. This is actually correct, to
allow the original goal (shrink the static pool to 0) to succeed (we are
converting hugepages to surplus because they are in use). However, the
documentation does not accurately reflect this case. Update it.

Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
Acked-by: Andy Whitcroft <apw@shadowen.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Nishanth Aravamudan and committed by
Linus Torvalds
423bec43 91446b06

+3 -4
+3 -4
Documentation/vm/hugetlbpage.txt
··· 88 88 these surplus hugepages go out of use, they are freed back to the buddy 89 89 allocator. 90 90 91 - Caveat: Shrinking the pool via nr_hugepages while a surplus is in effect 92 - will allow the number of surplus huge pages to exceed the overcommit 93 - value, as the pool hugepages (which must have been in use for a surplus 94 - hugepages to be allocated) will become surplus hugepages. As long as 91 + Caveat: Shrinking the pool via nr_hugepages such that it becomes less 92 + than the number of hugepages in use will convert the balance to surplus 93 + huge pages even if it would exceed the overcommit value. As long as 95 94 this condition holds, however, no more surplus huge pages will be 96 95 allowed on the system until one of the two sysctls are increased 97 96 sufficiently, or the surplus huge pages go out of use and are freed.