Skip to content

Commit a76584f

Browse files
Yonghong SongAlexei Starovoitov
authored andcommitted
selftests/bpf: Enable test test_progs-cpuv4 for gcc build kernel
Currently, test_progs-cpuv4 is generated with clang build kernel when bpf cpu=v4 is supported by the clang compiler. Let us enable test_progs-cpuv4 for gcc build kernel as well. Signed-off-by: Yonghong Song <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Alexei Starovoitov <[email protected]>
1 parent 09fedc7 commit a76584f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tools/testing/selftests/bpf/Makefile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,12 @@ LDLIBS += -lelf -lz -lrt -lpthread
3636
ifneq ($(LLVM),)
3737
# Silence some warnings when compiled with clang
3838
CFLAGS += -Wno-unused-command-line-argument
39-
# Check whether cpu=v4 is supported or not by clang
39+
endif
40+
41+
# Check whether bpf cpu=v4 is supported or not by clang
4042
ifneq ($(shell $(CLANG) --target=bpf -mcpu=help 2>&1 | grep 'v4'),)
4143
CLANG_CPUV4 := 1
4244
endif
43-
endif
4445

4546
# Order correspond to 'make run_tests' order
4647
TEST_GEN_PROGS = test_verifier test_tag test_maps test_lru_map test_lpm_map test_progs \

0 commit comments

Comments
 (0)