Skip to content

Commit fd0493a

Browse files
anakryikoborkmann
authored andcommitted
selftests/bpf: Switch fexit_stress to bpf_link_create() API
Use bpf_link_create() API in fexit_stress test to attach FEXIT programs. Signed-off-by: Andrii Nakryiko <[email protected]> Signed-off-by: Daniel Borkmann <[email protected]> Reviewed-by: Kui-Feng Lee <[email protected]> Link: https://lore.kernel.org/bpf/[email protected]
1 parent 8462e0b commit fd0493a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/testing/selftests/bpf/prog_tests/fexit_stress.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ void test_fexit_stress(void)
5353
&trace_opts);
5454
if (!ASSERT_GE(fexit_fd[i], 0, "fexit load"))
5555
goto out;
56-
link_fd[i] = bpf_raw_tracepoint_open(NULL, fexit_fd[i]);
56+
link_fd[i] = bpf_link_create(fexit_fd[i], 0, BPF_TRACE_FEXIT, NULL);
5757
if (!ASSERT_GE(link_fd[i], 0, "fexit attach"))
5858
goto out;
5959
}

0 commit comments

Comments
 (0)