selftests/bpf: Enable lld usage for RISC-V
authorBjörn Töpel <bjorn@rivosinc.com>
Wed, 4 Oct 2023 12:27:20 +0000 (14:27 +0200)
committerAndrii Nakryiko <andrii@kernel.org>
Wed, 4 Oct 2023 20:37:41 +0000 (13:37 -0700)
RISC-V has proper lld support. Use that, similar to what x86 does, for
urandom_read et al.

Signed-off-by: Björn Töpel <bjorn@rivosinc.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/bpf/20231004122721.54525-3-bjorn@kernel.org
tools/testing/selftests/bpf/Makefile

index dca2d4dadb2c1afa403b351d819dae8d799f6545..a28cf927bc59ad7ae7025acdafa6d032fcbda9e0 100644 (file)
@@ -188,7 +188,7 @@ $(OUTPUT)/%:%.c
        $(Q)$(LINK.c) $^ $(LDLIBS) -o $@
 
 # LLVM's ld.lld doesn't support all the architectures, so use it only on x86
-ifeq ($(SRCARCH),x86)
+ifeq ($(SRCARCH),$(filter $(SRCARCH),x86 riscv))
 LLD := lld
 else
 LLD := ld