1 // SPDX-License-Identifier: GPL-2.0 2 #include <vmlinux.h> 3 #include <bpf/bpf_helpers.h> 4 #include <bpf/bpf_tracing.h> 5 6 char _license[] SEC("license") = "GPL"; 7 8 __hidden extern int tracing_multi_arg_check(__u64 *ctx, __u64 *test_result, bool is_return); 9 10 __u64 test_result_fentry_1 = 0; 11 __u64 test_result_fentry_2 = 0; 12 __u64 test_result_fexit_1 = 0; 13 __u64 test_result_fexit_2 = 0; 14 15 SEC("fentry.multi") 16 int BPF_PROG(fentry_1) 17 { 18 tracing_multi_arg_check(ctx, &test_result_fentry_1, false); 19 return 0; 20 } 21 22 SEC("fentry.multi") 23 int BPF_PROG(fentry_2) 24 { 25 tracing_multi_arg_check(ctx, &test_result_fentry_2, false); 26 return 0; 27 } 28 29 SEC("fexit.multi") 30 int BPF_PROG(fexit_1) 31 { 32 tracing_multi_arg_check(ctx, &test_result_fexit_1, true); 33 return 0; 34 } 35 36 SEC("fexit.multi") 37 int BPF_PROG(fexit_2) 38 { 39 tracing_multi_arg_check(ctx, &test_result_fexit_2, true); 40 return 0; 41 } 42