Skip to content

Commit a55d4bb

Browse files
Ted Loganawilliam
authored andcommitted
vfio: selftests: only build tests on arm64 and x86_64
Only build vfio self-tests on arm64 and x86_64; these are the only architectures where the vfio self-tests are run. Addresses compiler warnings for format and conversions on i386. Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202601211830.aBEjmEFD-lkp@intel.com/ Signed-off-by: Ted Logan <tedlogan@fb.com> Reviewed-by: David Matlack <dmatlack@google.com> Link: https://lore.kernel.org/r/20260202-vfio-selftest-only-64bit-v2-1-9c3ebb37f0f4@fb.com Signed-off-by: Alex Williamson <alex@shazbot.org>
1 parent c3cbc27 commit a55d4bb

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

tools/testing/selftests/vfio/Makefile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
ARCH ?= $(shell uname -m)
2+
3+
ifeq (,$(filter $(ARCH),arm64 x86_64))
4+
# Do nothing on unsupported architectures
5+
include ../lib.mk
6+
else
7+
18
CFLAGS = $(KHDR_INCLUDES)
29
TEST_GEN_PROGS += vfio_dma_mapping_test
310
TEST_GEN_PROGS += vfio_dma_mapping_mmio_test
@@ -28,3 +35,5 @@ TEST_DEP_FILES = $(patsubst %.o, %.d, $(TEST_GEN_PROGS_O) $(LIBVFIO_O))
2835
-include $(TEST_DEP_FILES)
2936

3037
EXTRA_CLEAN += $(TEST_GEN_PROGS_O) $(TEST_DEP_FILES)
38+
39+
endif

0 commit comments

Comments
 (0)