]> git.baikalelectronics.ru Git - kernel.git/commit
selftests, bpf: Fix broken riscv build
authorBjörn Töpel <bjorn@kernel.org>
Thu, 28 Oct 2021 16:10:57 +0000 (18:10 +0200)
committerDaniel Borkmann <daniel@iogearbox.net>
Mon, 1 Nov 2021 16:10:40 +0000 (17:10 +0100)
commit25a2831e0444454fa0a6a6812dbb78b51ce9ebf0
tree5ee619da6c3c21b0d751c823fd2a3effcc30a977
parentd3adad81877eae42f42303ea5584086f2af803e6
selftests, bpf: Fix broken riscv build

This patch is closely related to commit e14652ec3de8 ("selftests/bpf:
Fix broken riscv build"). When clang includes the system include
directories, but targeting BPF program, __BITS_PER_LONG defaults to
32, unless explicitly set. Work around this problem, by explicitly
setting __BITS_PER_LONG to __riscv_xlen.

Signed-off-by: Björn Töpel <bjorn@kernel.org>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Link: https://lore.kernel.org/bpf/20211028161057.520552-5-bjorn@kernel.org
tools/testing/selftests/bpf/Makefile