]> git.baikalelectronics.ru Git - kernel.git/commit
mm, shmem: fix handling /sys/kernel/mm/transparent_hugepage/shmem_enabled
authorKirill A. Shutemov <kirill.shutemov@linux.intel.com>
Fri, 25 Aug 2017 22:55:33 +0000 (15:55 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 25 Aug 2017 23:12:46 +0000 (16:12 -0700)
commita9f22ffcc1954d248ff8df369949a30a666a5da7
treefa01aec77d23c086e9f23650f12bc16ce94d5ff9
parent9bd2faf3a07b2de138033778603c07decd83a4eb
mm, shmem: fix handling /sys/kernel/mm/transparent_hugepage/shmem_enabled

/sys/kernel/mm/transparent_hugepage/shmem_enabled controls if we want
to allocate huge pages when allocate pages for private in-kernel shmem
mount.

Unfortunately, as Dan noticed, I've screwed it up and the only way to
make kernel allocate huge page for the mount is to use "force" there.
All other values will be effectively ignored.

Link: http://lkml.kernel.org/r/20170822144254.66431-1-kirill.shutemov@linux.intel.com
Fixes: 10fb1f0a10fd ("shmem: prepare huge= mount option and sysfs knob")
Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Cc: stable <stable@vger.kernel.org> [4.8+]
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/shmem.c