Skip to content
Commit a2e8bbd2 authored by Martin KaFai Lau's avatar Martin KaFai Lau Committed by David S. Miller
Browse files

bpf: Fix test_obj_id.c for llvm 5.0

llvm 5.0 does not like the section name and the function name
to be the same:

clang -I. -I./include/uapi -I../../../include/uapi \
	-I../../../../samples/bpf/ \
	-Wno-compare-distinct-pointer-types \
	-O2 -target bpf -c \
	linux/tools/testing/selftests/bpf/test_obj_id.c -o \
	linux/tools/testing/selftests/bpf/test_obj_id.o
fatal error: error in backend: 'test_prog_id' label emitted multiple times to
assembly file
clang-5.0: error: clang frontend command failed with exit code 70 (use -v to
see invocation)
clang version 5.0.0 (trunk 304326) (llvm/trunk 304329)

This patch makes changes to the section name and the function name.

Fixes: 95b9afd3

 ("bpf: Test for bpf ID")
Reported-by: default avatarAlexei Starovoitov <ast@fb.com>
Reported-by: default avatarYonghong Song <yhs@fb.com>
Signed-off-by: default avatarMartin KaFai Lau <kafai@fb.com>
Acked-by: default avatarDaniel Borkmann <daniel@iogearbox.net>
Acked-by: default avatarYonghong Song <yhs@fb.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent fad07430
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment