xref: /linux/tools/testing/selftests/bpf/progs/cgroup_mprog.c (revision d9104cec3e8fe4b458b74709853231385779001f)
1 // SPDX-License-Identifier: GPL-2.0
2 /* Copyright (c) 2025 Meta Platforms, Inc. and affiliates. */
3 #include <vmlinux.h>
4 #include <bpf/bpf_helpers.h>
5 
6 char _license[] SEC("license") = "GPL";
7 
8 SEC("cgroup/getsockopt")
getsockopt_1(struct bpf_sockopt * ctx)9 int getsockopt_1(struct bpf_sockopt *ctx)
10 {
11 	return 1;
12 }
13 
14 SEC("cgroup/getsockopt")
getsockopt_2(struct bpf_sockopt * ctx)15 int getsockopt_2(struct bpf_sockopt *ctx)
16 {
17 	return 1;
18 }
19 
20 SEC("cgroup/getsockopt")
getsockopt_3(struct bpf_sockopt * ctx)21 int getsockopt_3(struct bpf_sockopt *ctx)
22 {
23 	return 1;
24 }
25 
26 SEC("cgroup/getsockopt")
getsockopt_4(struct bpf_sockopt * ctx)27 int getsockopt_4(struct bpf_sockopt *ctx)
28 {
29 	return 1;
30 }
31