Home
last modified time | relevance | path

Searched refs:allow_prog (Results 1 – 4 of 4) sorted by relevance

/linux-6.3-rc2/tools/testing/selftests/bpf/prog_tests/
A Dcgroup_attach_multi.c82 int allow_prog[7] = {-1}; in serial_test_cgroup_attach_multi() local
87 for (i = 0; i < ARRAY_SIZE(allow_prog); i++) { in serial_test_cgroup_attach_multi()
88 allow_prog[i] = prog_load_cnt(1, 1 << i); in serial_test_cgroup_attach_multi()
89 if (CHECK(allow_prog[i] < 0, "prog_load", in serial_test_cgroup_attach_multi()
196 attach_opts.replace_prog_fd = allow_prog[0]; in serial_test_cgroup_attach_multi()
219 attach_opts.replace_prog_fd = allow_prog[3]; in serial_test_cgroup_attach_multi()
227 attach_opts.replace_prog_fd = allow_prog[0]; in serial_test_cgroup_attach_multi()
234 attach_opts.replace_prog_fd = allow_prog[6]; in serial_test_cgroup_attach_multi()
283 for (i = 0; i < ARRAY_SIZE(allow_prog); i++) in serial_test_cgroup_attach_multi()
284 if (allow_prog[i] >= 0) in serial_test_cgroup_attach_multi()
[all …]
A Dcgroup_attach_autodetach.c27 int allow_prog[2] = {-1}; in serial_test_cgroup_attach_autodetach() local
33 for (i = 0; i < ARRAY_SIZE(allow_prog); i++) { in serial_test_cgroup_attach_autodetach()
34 allow_prog[i] = prog_load(); in serial_test_cgroup_attach_autodetach()
35 if (CHECK(allow_prog[i] < 0, "prog_load", in serial_test_cgroup_attach_autodetach()
51 for (i = 0; i < ARRAY_SIZE(allow_prog); i++) in serial_test_cgroup_attach_autodetach()
52 if (CHECK(bpf_prog_attach(allow_prog[i], cg, in serial_test_cgroup_attach_autodetach()
73 close(allow_prog[i]); in serial_test_cgroup_attach_autodetach()
74 allow_prog[i] = -1; in serial_test_cgroup_attach_autodetach()
104 for (i = 0; i < ARRAY_SIZE(allow_prog); i++) in serial_test_cgroup_attach_autodetach()
105 if (allow_prog[i] >= 0) in serial_test_cgroup_attach_autodetach()
[all …]
A Dcgroup_attach_override.c28 int drop_prog = -1, allow_prog = -1, foo = -1, bar = -1; in serial_test_cgroup_attach_override() local
31 allow_prog = prog_load(1); in serial_test_cgroup_attach_override()
32 if (CHECK(allow_prog < 0, "prog_load_allow", in serial_test_cgroup_attach_override()
63 if (CHECK(bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, in serial_test_cgroup_attach_override()
81 if (CHECK(bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, in serial_test_cgroup_attach_override()
95 if (CHECK(bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, in serial_test_cgroup_attach_override()
101 if (CHECK(!bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, 0), in serial_test_cgroup_attach_override()
116 if (CHECK(bpf_prog_attach(allow_prog, foo, BPF_CGROUP_INET_EGRESS, 0), in serial_test_cgroup_attach_override()
126 if (CHECK(!bpf_prog_attach(allow_prog, bar, BPF_CGROUP_INET_EGRESS, in serial_test_cgroup_attach_override()
132 if (CHECK(!bpf_prog_attach(allow_prog, foo, BPF_CGROUP_INET_EGRESS, in serial_test_cgroup_attach_override()
[all …]
/linux-6.3-rc2/tools/testing/selftests/seccomp/
A Dseccomp_bpf.c3188 struct sock_fprog allow_prog = { in TEST_SIGNAL() local
3204 &allow_prog); in TEST_SIGNAL()
3216 ret = seccomp(SECCOMP_SET_MODE_FILTER, 0, &allow_prog); in TEST_SIGNAL()
3221 &allow_prog); in TEST_SIGNAL()

Completed in 15 milliseconds