mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] selftests: prctl: don't fail to build when cross compiling
@ 2026-10-11 22:33 Sasha Levin
  0 siblings, 0 replies; only message in thread
From: Sasha Levin @ 2026-10-11 22:33 UTC (permalink / raw)
  To: Shuah Khan, Ivan Orlov
  Cc: Sasha Levin, stable, Shuah Khan, linux-kselftest, linux-kernel

The prctl Makefile includes lib.mk only for native x86 builds. With
CROSS_COMPILE set, or for other architectures, it defines no targets at
all, and since prctl is in the default selftests TARGETS, the build
fails:

  make: *** No targets.  Stop.

Include lib.mk unconditionally, so that those builds have nothing to do
instead of failing. Native x86 builds are unchanged.

Fixes: 5290586186d24 ("selftests: prctl: Add new prctl test for PR_SET_VMA action")
Cc: stable@vger.kernel.org
Assisted-by: LLM
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 tools/testing/selftests/prctl/Makefile | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/tools/testing/selftests/prctl/Makefile b/tools/testing/selftests/prctl/Makefile
index e770e86fad9ac..c321bd60740cb 100644
--- a/tools/testing/selftests/prctl/Makefile
+++ b/tools/testing/selftests/prctl/Makefile
@@ -7,8 +7,7 @@ ifeq ($(ARCH),x86)
 TEST_PROGS := disable-tsc-ctxt-sw-stress-test disable-tsc-on-off-stress-test \
 		disable-tsc-test set-anon-vma-name-test set-process-name
 all: $(TEST_PROGS)
-
-include ../lib.mk
-
 endif
 endif
+
+include ../lib.mk
-- 
2.53.0


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

only message in thread, other threads:[~2026-10-11 22:34 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-11 22:33 [PATCH] selftests: prctl: don't fail to build when cross compiling Sasha Levin

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

all inboxes | Powered by JetHome®