Linux Kernel Selftest development
 help / color / mirror / Atom feed
* [PATCH] selftests/mm: include linux/mman.h for prctl_thp_disable
@ 2025-09-10 20:46 Usama Arif
  0 siblings, 0 replies; only message in thread
From: Usama Arif @ 2025-09-10 20:46 UTC (permalink / raw)
  To: Andrew Morton
  Cc: david, lorenzo.stoakes, Liam.Howlett, vbabka, rppt, surenb,
	mhocko, shuah, linux-mm, linux-kselftest, linux-kernel,
	Usama Arif, Mark Brown

MADV_COLLAPSE is part of linux/mman.h and needs to be included
for this selftest for glibc compatibility. It is also included
in other tests that use MADV_COLLAPSE.

Fixes: d9c7ff4dae62 ("selftests: prctl: introduce tests for disabling THPs completely")
Reported-by: Mark Brown <broonie@kernel.org>
Closes: https://lore.kernel.org/all/c8249725-e91d-4c51-b9bb-40305e61e20d@sirena.org.uk/
Signed-off-by: Usama Arif <usamaarif642@gmail.com>
---
 tools/testing/selftests/mm/prctl_thp_disable.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/testing/selftests/mm/prctl_thp_disable.c b/tools/testing/selftests/mm/prctl_thp_disable.c
index feb711dca3a1d..84b4a4b345af5 100644
--- a/tools/testing/selftests/mm/prctl_thp_disable.c
+++ b/tools/testing/selftests/mm/prctl_thp_disable.c
@@ -9,6 +9,7 @@
 #include <string.h>
 #include <unistd.h>
 #include <sys/mman.h>
+#include <linux/mman.h>
 #include <sys/prctl.h>
 #include <sys/wait.h>
 
-- 
2.47.3


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2025-09-10 20:46 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-10 20:46 [PATCH] selftests/mm: include linux/mman.h for prctl_thp_disable Usama Arif

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox