Skip to content

Commit a2282a6

Browse files
Alexei Starovoitovqmonnet
authored andcommitted
libbpf, selftests/bpf: Adjust libbpf, bpftool, selftests to match LLVM
The selftests use to tell LLVM about special pointers. For LLVM there is nothing "arena" about them. They are simply pointers in a different address space. Hence LLVM diff llvm/llvm-project#85161 renamed: . macro __BPF_FEATURE_ARENA_CAST -> __BPF_FEATURE_ADDR_SPACE_CAST . global variables in __attribute__((address_space(N))) are now placed in section named ".addr_space.N" instead of ".arena.N". Adjust libbpf, bpftool, and selftests to match LLVM. Signed-off-by: Alexei Starovoitov <[email protected]> Signed-off-by: Andrii Nakryiko <[email protected]> Acked-by: Stanislav Fomichev <[email protected]> Link: https://lore.kernel.org/bpf/[email protected]
1 parent 5a86201 commit a2282a6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/gen.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ static bool get_datasec_ident(const char *sec_name, char *buf, size_t buf_sz)
121121
int i, n;
122122

123123
/* recognize hard coded LLVM section name */
124-
if (strcmp(sec_name, ".arena.1") == 0) {
124+
if (strcmp(sec_name, ".addr_space.1") == 0) {
125125
/* this is the name to use in skeleton */
126126
snprintf(buf, buf_sz, "arena");
127127
return true;

0 commit comments

Comments
 (0)