1 // SPDX-License-Identifier: GPL-2.0 2 3 #include <vmlinux.h> 4 #include <bpf/bpf_helpers.h> 5 #include <bpf/bpf_tracing.h> 6 #include "../bpf_testmod/bpf_testmod.h" 7 8 char _license[] SEC("license") = "GPL"; 9 10 SEC("struct_ops/test_1") 11 int BPF_PROG(test_1) { return 0; } 12 13 SEC("struct_ops/test_2") 14 int BPF_PROG(test_2) { return 0; } 15 16 SEC(".struct_ops.link") 17 struct bpf_testmod_ops testmod_1 = { 18 .test_1 = (void *)test_1, 19 .test_2 = (void *)test_2 20 }; 21 22 SEC(".struct_ops.link") 23 struct bpf_testmod_ops2 testmod_2 = { 24 .test_1 = (void *)test_1 25 }; 26