[pve-devel] [PATCH kernel 1/4] set transparent hugepages to madvise by default

Fabian Gr├╝nbichler f.gruenbichler at proxmox.com
Fri Jan 20 09:50:55 CET 2017


"never" is mainly for debugging purposes, and causes
increased memory fragmentation.

"madvise" is the conservative option - only programs
requesting huge pages via madvise get them, e.g. Qemu.

Signed-off-by: Fabian Gr├╝nbichler <f.gruenbichler at proxmox.com>
---
 Makefile                   |  4 +---
 add-thp-never-option.patch | 15 ---------------
 2 files changed, 1 insertion(+), 18 deletions(-)
 delete mode 100644 add-thp-never-option.patch

diff --git a/Makefile b/Makefile
index 89d266f..dfb2060 100644
--- a/Makefile
+++ b/Makefile
@@ -209,9 +209,8 @@ data: .compile_mark igb.ko ixgbe.ko e1000e.ko ${SPL_MODULES} ${ZFS_MODULES} ${DR
 PVE_CONFIG_OPTS= \
 -m INTEL_MEI_WDT \
 -d CONFIG_SND_PCM_OSS \
--d CONFIG_TRANSPARENT_HUGEPAGE_MADVISE \
+-e CONFIG_TRANSPARENT_HUGEPAGE_MADVISE \
 -d CONFIG_TRANSPARENT_HUGEPAGE_ALWAYS \
--e CONFIG_TRANSPARENT_HUGEPAGE_NEVER \
 -m CONFIG_CEPH_FS \
 -m CONFIG_BLK_DEV_NBD \
 -m CONFIG_BLK_DEV_RBD \
@@ -251,7 +250,6 @@ ${KERNEL_SRC}/README ${KERNEL_CFG_ORG}: ${KERNELSRCTAR}
 	rm -rf ${KERNEL_SRC}
 	tar xf ${KERNELSRCTAR}
 	cat ${KERNEL_SRC}/debian.master/config/config.common.ubuntu ${KERNEL_SRC}/debian.master/config/amd64/config.common.amd64 ${KERNEL_SRC}/debian.master/config/amd64/config.flavour.generic > ${KERNEL_CFG_ORG}
-	cd ${KERNEL_SRC}; patch -p1 <../add-thp-never-option.patch
 	cd ${KERNEL_SRC}; patch -p1 <../bridge-patch.diff
 	#cd ${KERNEL_SRC}; patch -p1 <../bridge-forward-ipv6-neighbor-solicitation.patch
 	#cd ${KERNEL_SRC}; patch -p1 <../add-empty-ndo_poll_controller-to-veth.patch
diff --git a/add-thp-never-option.patch b/add-thp-never-option.patch
deleted file mode 100644
index 7589db5..0000000
--- a/add-thp-never-option.patch
+++ /dev/null
@@ -1,15 +0,0 @@
---- ubuntu-wily/mm/Kconfig.org	2015-09-15 09:46:53.770389180 +0200
-+++ ubuntu-wily/mm/Kconfig	2015-09-15 09:48:05.813854679 +0200
-@@ -444,6 +444,12 @@
- 	  madvise(MADV_HUGEPAGE) but it won't risk to increase the
- 	  memory footprint of applications without a guaranteed
- 	  benefit.
-+
-+	config TRANSPARENT_HUGEPAGE_NEVER
-+		bool "never"
-+	help
-+	  Disable Transparent Hugepage
-+
- endchoice
- 
- #
-- 
2.1.4




More information about the pve-devel mailing list