Skip to contentSkip to conversation

selftests/kexec: don't fail the build on other architectures

PATCH New Sasha Levin 2 participants 2 messages Nov 4

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 selftests/kexec: don't fail the build on other architectures

The kexec tests are only built for x86 and ppc64le. On other architectures the Makefile defines no rules, so building or installing the suite fails:

make[1]: *** No targets. Stop.

Give the Makefile empty targets there, as sparc64 and drivers/s390x/uvdevice do, so that the suite builds and installs nothing.

Fixes a802ed0dd9c2 ("selftests/ima: kexec_load syscall test")

---
Found with KernelCI-style TuxMake builds that record per-suite results with KSFT_BUILD_REPORT. x86_64 builds don't change, and arm64 and arm builds now succeed without installing anything.

With ARCH=powerpc, as passed by the kernel's kselftest targets and by CI, the ppc64le check doesn't match either, so the tests are only built on powerpc when ARCH is taken from uname -m. This patch leaves that alone.

 tools/testing/selftests/kexec/Makefile | 4 ++++
 1 file changed, 4 insertions(+)
tools/testing/selftests/kexec/Makefile +4 -0
index 874cfdd3b75b3..11b30d49a7f23 100644
@@ -17,4 +17,8 @@ endif
 
 include ../lib.mk
 
+else
+nothing:
+.PHONY: all clean run_tests install
+.SILENT:
 endif
Signature · 1 line
2.53.0
#1 lore raw
Sashiko has reviewed this patch and found no issues.
Quoted 4 lines

The kexec tests are only built for x86 and ppc64le. On other architectures the Makefile defines no rules, so building or installing the suite fails:

Quoted 8 lines

make[1]: *** No targets. Stop.

Give the Makefile empty targets there, as sparc64 and drivers/s390x/uvdevice do, so that the suite builds and installs nothing.

Fixes a802ed0dd9c2 ("selftests/ima: kexec_load syscall test")

Sashiko has reviewed this patch and found no issues.

Signature · 1 line
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1