Skip to content

Commit 564f013

Browse files
committed
selftests: bpf: trigger arena list_del() bug.
Comment out the bpf_free() from arena_list_del() so the nodes are removed by list_del() but the memory is not freed, this will trigger a bug showing that list_del is doesn't remove nodes and just poisons the next and pprev pointers. Signed-off-by: Puranjay Mohan <puranjay@kernel.org>
1 parent 48a97ff commit 564f013

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/testing/selftests/bpf/progs/arena_list.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ int arena_list_del(void *ctx)
7676
sum += n->value;
7777
arena_sum += n->value;
7878
list_del(&n->node);
79-
bpf_free(n);
79+
//bpf_free(n);
8080
}
8181
list_sum = sum;
8282
#else

0 commit comments

Comments
 (0)