/linux-6.6.21/tools/testing/selftests/landlock/ |
D | fs_test.c | 155 static void mkdir_parents(struct __test_metadata *const _metadata, in mkdir_parents() argument 181 static void create_directory(struct __test_metadata *const _metadata, in create_directory() argument 184 mkdir_parents(_metadata, path); in create_directory() 192 static void create_file(struct __test_metadata *const _metadata, in create_file() argument 195 mkdir_parents(_metadata, path); in create_file() 257 static void prepare_layout_opt(struct __test_metadata *const _metadata, in prepare_layout_opt() argument 260 disable_caps(_metadata); in prepare_layout_opt() 262 create_directory(_metadata, TMP_DIR); in prepare_layout_opt() 268 set_cap(_metadata, CAP_SYS_ADMIN); in prepare_layout_opt() 283 clear_cap(_metadata, CAP_SYS_ADMIN); in prepare_layout_opt() [all …]
|
D | common.h | 36 struct __test_metadata *_metadata, \ 46 _metadata->no_print = 1; \ 47 fixture_name##_##test_name##_child(_metadata, self, variant); \ 48 if (_metadata->skip) \ 50 if (_metadata->passed) \ 52 _exit(_metadata->step); \ 57 _metadata->passed = 0; \ 58 _metadata->step = 1; \ 63 _metadata->passed = 1; \ 66 _metadata->passed = 1; \ [all …]
|
D | ptrace_test.c | 28 static void create_domain(struct __test_metadata *const _metadata) in create_domain() argument 310 drop_caps(_metadata); in TEST_F() 316 create_domain(_metadata); in TEST_F() 317 if (!_metadata->passed) in TEST_F() 330 create_domain(_metadata); in TEST_F() 378 _exit(_metadata->passed ? EXIT_SUCCESS : EXIT_FAILURE); in TEST_F() 385 create_domain(_metadata); in TEST_F() 435 _metadata->passed = 0; in TEST_F()
|
D | base_test.c | 212 drop_caps(_metadata); in TEST() 243 drop_caps(_metadata); in TEST() 270 drop_caps(_metadata); in TEST() 310 _exit(_metadata->passed ? EXIT_SUCCESS : EXIT_FAILURE); in TEST()
|
/linux-6.6.21/tools/testing/selftests/net/ |
D | so_incoming_cpu.c | 56 static void write_sysctl(struct __test_metadata *_metadata, in write_sysctl() argument 69 static void setup_netns(struct __test_metadata *_metadata) in setup_netns() argument 74 write_sysctl(_metadata, "/proc/sys/net/ipv4/ip_local_port_range", "10000 60001"); in setup_netns() 75 write_sysctl(_metadata, "/proc/sys/net/ipv4/tcp_tw_reuse", "0"); in setup_netns() 84 setup_netns(_metadata); in FIXTURE_SETUP() 115 void set_so_incoming_cpu(struct __test_metadata *_metadata, int fd, int cpu) in set_so_incoming_cpu() argument 123 int create_server(struct __test_metadata *_metadata, in create_server() argument 134 set_so_incoming_cpu(_metadata, fd, cpu); in create_server() 143 set_so_incoming_cpu(_metadata, fd, cpu); in create_server() 152 set_so_incoming_cpu(_metadata, fd, cpu); in create_server() [all …]
|
D | tls.c | 109 static void ulp_sock_pair(struct __test_metadata *_metadata, in ulp_sock_pair() argument 182 static int tls_recv_cmsg(struct __test_metadata *_metadata, in tls_recv_cmsg() argument 221 ulp_sock_pair(_metadata, &self->fd, &self->cfd, &self->notls); in FIXTURE_SETUP() 377 ulp_sock_pair(_metadata, &self->fd, &self->cfd, &self->notls); in FIXTURE_SETUP() 432 static void chunked_sendfile(struct __test_metadata *_metadata, in chunked_sendfile() argument 469 chunked_sendfile(_metadata, self, 4096, 4096); in TEST_F() 470 chunked_sendfile(_metadata, self, 4096, 0); in TEST_F() 471 chunked_sendfile(_metadata, self, 4096, 1); in TEST_F() 472 chunked_sendfile(_metadata, self, 4096, 2048); in TEST_F() 473 chunked_sendfile(_metadata, self, 8192, 2048); in TEST_F() [all …]
|
D | reuseaddr_ports_exhausted.c | 54 int bind_port(struct __test_metadata *_metadata, int reuseaddr, int reuseport) in bind_port() argument 90 fd[j] = bind_port(_metadata, opts->reuseaddr[j], opts->reuseport[j]); in TEST() 110 fd[j] = bind_port(_metadata, opts->reuseaddr[j], opts->reuseport[j]); in TEST() 139 fd[j] = bind_port(_metadata, opts->reuseaddr[j], opts->reuseport[j]); in TEST()
|
D | bind_wildcard.c | 111 void bind_sockets(struct __test_metadata *_metadata, in bind_sockets() argument 148 bind_sockets(_metadata, self, variant->expected_errno, in TEST_F() 155 bind_sockets(_metadata, self, variant->expected_errno, in TEST_F()
|
D | bind_timewait.c | 42 void create_timewait_socket(struct __test_metadata *_metadata, in create_timewait_socket() argument 80 create_timewait_socket(_metadata, self);
|
/linux-6.6.21/tools/testing/selftests/ |
D | kselftest_harness.h | 115 __FILE__, __LINE__, _metadata->name, ##__VA_ARGS__) 132 snprintf(_metadata->results->reason, \ 133 sizeof(_metadata->results->reason), fmt, ##__VA_ARGS__); \ 136 _metadata->results->reason); \ 138 _metadata->passed = 1; \ 139 _metadata->skip = 1; \ 140 _metadata->trigger = 0; \ 183 static void test_name(struct __test_metadata *_metadata); \ 185 struct __test_metadata *_metadata, \ 188 _metadata->setup_completed = true; \ [all …]
|
/linux-6.6.21/tools/testing/selftests/hid/ |
D | hid_bpf.c | 117 static int uhid_write(struct __test_metadata *_metadata, int fd, const struct uhid_event *ev) in uhid_write() argument 134 static int uhid_create(struct __test_metadata *_metadata, int fd, int rand_nb) in uhid_create() argument 155 return uhid_write(_metadata, fd, &ev); in uhid_create() 158 static void uhid_destroy(struct __test_metadata *_metadata, int fd) in uhid_destroy() argument 165 uhid_write(_metadata, fd, &ev); in uhid_destroy() 168 static int uhid_event(struct __test_metadata *_metadata, int fd) in uhid_event() argument 218 uhid_write(_metadata, fd, &answer); in uhid_event() 233 struct __test_metadata *_metadata; member 238 struct __test_metadata *_metadata = args->_metadata; in uhid_read_events_thread() local 255 ret = uhid_event(_metadata, fd); in uhid_read_events_thread() [all …]
|
/linux-6.6.21/tools/testing/selftests/exec/ |
D | non-regular.c | 15 void rm(struct __test_metadata *_metadata, const char *pathname, in rm() argument 46 void (*setup)(struct __test_metadata *_metadata, in FIXTURE_VARIANT() 52 void setup_link(struct __test_metadata *_metadata, in setup_link() argument 80 void setup_dir(struct __test_metadata *_metadata, in setup_dir() argument 95 void setup_node(struct __test_metadata *_metadata, in setup_node() argument 133 void setup_fifo(struct __test_metadata *_metadata, in setup_fifo() argument 152 rm(_metadata, self->pathname, variant->is_dir); in FIXTURE_SETUP() 153 variant->setup(_metadata, self, variant); in FIXTURE_SETUP() 158 rm(_metadata, self->pathname, self->is_dir); in FIXTURE_TEARDOWN()
|
/linux-6.6.21/tools/testing/selftests/filesystems/binderfs/ |
D | binderfs_test.c | 39 static void change_mountns(struct __test_metadata *_metadata) in change_mountns() argument 56 static int __do_binderfs_test(struct __test_metadata *_metadata) in __do_binderfs_test() argument 70 change_mountns(_metadata); in __do_binderfs_test() 294 static void change_userns(struct __test_metadata *_metadata, int syncfds[2]) in change_userns() argument 324 static void change_idmaps(struct __test_metadata *_metadata, int syncfds[2], pid_t pid) in change_idmaps() argument 360 struct __test_metadata *_metadata = _thread_metadata; in binder_version_thread() local 406 change_userns(_metadata, syncfds); in TEST() 407 change_mountns(_metadata); in TEST() 457 _thread_metadata = _metadata; in TEST() 486 change_idmaps(_metadata, syncfds, pid); in TEST() [all …]
|
/linux-6.6.21/tools/testing/selftests/net/af_unix/ |
D | diag_uid.c | 76 int send_request(struct __test_metadata *_metadata, in send_request() argument 116 void render_response(struct __test_metadata *_metadata, in render_response() argument 134 void receive_response(struct __test_metadata *_metadata, in receive_response() argument 161 render_response(_metadata, NLMSG_DATA(nlh), nlh->nlmsg_len); in receive_response() 171 ret = send_request(_metadata, self, variant); 174 receive_response(_metadata, self);
|
/linux-6.6.21/tools/testing/selftests/clone3/ |
D | clone3_cap_checkpoint_restore.c | 41 static int call_clone3_set_tid(struct __test_metadata *_metadata, in call_clone3_set_tid() argument 83 static int test_clone3_set_tid(struct __test_metadata *_metadata, in test_clone3_set_tid() argument 89 ret = call_clone3_set_tid(_metadata, set_tid, set_tid_size); in test_clone3_set_tid() 175 ASSERT_EQ(test_clone3_set_tid(_metadata, set_tid, 1), -EPERM); in TEST() 179 ASSERT_EQ(test_clone3_set_tid(_metadata, set_tid, 1), 0); in TEST()
|
/linux-6.6.21/tools/testing/selftests/iommu/ |
D | iommufd_fail_nth.c | 89 static void fail_nth_first(struct __test_metadata *_metadata, in fail_nth_first() argument 99 static bool fail_nth_next(struct __test_metadata *_metadata, in fail_nth_next() argument 159 void __fail_nth_enable(struct __test_metadata *_metadata, in __fail_nth_enable() argument 171 #define fail_nth_enable() __fail_nth_enable(_metadata, _nth_state) 174 static int test_nth_##name(struct __test_metadata *_metadata, \ 187 fail_nth_first(_metadata, &nth_state); \ 188 ASSERT_EQ(0, test_nth_##name(_metadata, self, variant, \ 190 while (fail_nth_next(_metadata, &nth_state, test_result)) { \ 191 fixture_name##_teardown(_metadata, self, variant); \ 192 fixture_name##_setup(_metadata, self, variant); \ [all …]
|
D | iommufd.c | 66 teardown_iommufd(self->fd, _metadata); in FIXTURE_TEARDOWN() 224 teardown_iommufd(self->fd, _metadata); in FIXTURE_TEARDOWN() 762 static void check_access_rw(struct __test_metadata *_metadata, int fd, in check_access_rw() argument 831 check_access_rw(_metadata, self->fd, access_id, iova, 0); in TEST_F() 832 check_access_rw(_metadata, self->fd, access_id, iova, in TEST_F() 848 check_access_rw(_metadata, self->fd, access_id, iova, 0); in TEST_F() 876 check_access_rw(_metadata, self->fd, access_id, in TEST_F() 925 check_access_rw(_metadata, self->fd, access_id, MOCK_APERTURE_START, 0); in TEST_F() 1112 teardown_iommufd(self->fd, _metadata); in FIXTURE_TEARDOWN() 1548 teardown_iommufd(self->fd, _metadata); in FIXTURE_TEARDOWN() [all …]
|
D | iommufd_utils.h | 327 static void teardown_iommufd(int fd, struct __test_metadata *_metadata) in teardown_iommufd() argument
|
/linux-6.6.21/tools/testing/selftests/drivers/s390x/uvdevice/ |
D | test_uvdevice.c | 187 struct __test_metadata *_metadata, in att_inval_sizes_test() argument 217 false, _metadata, self); in TEST_F() 219 true, _metadata, self); in TEST_F() 221 true, _metadata, self); in TEST_F() 234 static void att_inval_addr_test(__u64 *addr, struct __test_metadata *_metadata, in att_inval_addr_test() argument 255 att_inval_addr_test(&self->uvio_attest.arcb_addr, _metadata, self); in TEST_F() 256 att_inval_addr_test(&self->uvio_attest.add_data_addr, _metadata, self); in TEST_F() 257 att_inval_addr_test(&self->uvio_attest.meas_addr, _metadata, self); in TEST_F()
|
/linux-6.6.21/tools/testing/selftests/perf_events/ |
D | sigtrap_threads.c | 149 static void run_test_threads(struct __test_metadata *_metadata, in run_test_threads() argument 161 run_test_threads(_metadata, self); in TEST_F() 169 run_test_threads(_metadata, self); in TEST_F() 188 run_test_threads(_metadata, self); in TEST_F() 207 run_test_threads(_metadata, self); in TEST_F()
|
/linux-6.6.21/tools/testing/selftests/seccomp/ |
D | seccomp_bpf.c | 801 void kill_thread_or_group(struct __test_metadata *_metadata, in kill_thread_or_group() argument 872 kill_thread_or_group(_metadata, KILL_THREAD); in TEST() 891 kill_thread_or_group(_metadata, KILL_PROCESS); in TEST() 910 kill_thread_or_group(_metadata, RET_UNKNOWN); in TEST() 1510 typedef void tracer_func_t(struct __test_metadata *_metadata, 1513 void start_tracer(struct __test_metadata *_metadata, int fd, pid_t tracee, in start_tracer() argument 1572 tracer_func(_metadata, tracee, status, args); in start_tracer() 1579 syscall(__NR_exit, _metadata->passed ? EXIT_SUCCESS : EXIT_FAILURE); in start_tracer() 1585 pid_t setup_trace_fixture(struct __test_metadata *_metadata, in setup_trace_fixture() argument 1602 start_tracer(_metadata, pipefd[1], tracee, func, args, in setup_trace_fixture() [all …]
|
/linux-6.6.21/tools/testing/selftests/sgx/ |
D | main.c | 176 struct __test_metadata *_metadata) in setup_test_encl() argument 287 ASSERT_TRUE(setup_test_encl(ENCL_HEAP_SIZE_DEFAULT, &self->encl, _metadata)); in TEST_F() 360 ASSERT_TRUE(setup_test_encl(total_mem, &self->encl, _metadata)); in TEST_F() 404 ASSERT_TRUE(setup_test_encl(total_mem, &self->encl, _metadata)); 509 ASSERT_TRUE(setup_test_encl(ENCL_HEAP_SIZE_DEFAULT, &self->encl, _metadata)); in TEST_F() 545 ASSERT_TRUE(setup_test_encl(ENCL_HEAP_SIZE_DEFAULT, &self->encl, _metadata)); in TEST_F() 578 ASSERT_TRUE(setup_test_encl(ENCL_HEAP_SIZE_DEFAULT, &self->encl, _metadata)); in TEST_F() 623 ASSERT_TRUE(setup_test_encl(ENCL_HEAP_SIZE_DEFAULT, &self->encl, _metadata)); in TEST_F() 725 ASSERT_TRUE(setup_test_encl(ENCL_HEAP_SIZE_DEFAULT, &self->encl, _metadata)); in TEST_F() 788 ASSERT_TRUE(setup_test_encl(ENCL_HEAP_SIZE_DEFAULT, &self->encl, _metadata)); in TEST_F() [all …]
|
/linux-6.6.21/Documentation/userspace-api/media/v4l/ |
D | dev-meta.rst | 3 .. _metadata:
|
/linux-6.6.21/drivers/net/netdevsim/ |
D | dev.c | 674 #define NSIM_TRAP_DROP_EXT(_id, _group_id, _metadata) \ argument 677 NSIM_TRAP_METADATA | (_metadata))
|
/linux-6.6.21/drivers/net/ethernet/mellanox/mlxsw/ |
D | spectrum_trap.c | 387 #define MLXSW_SP_TRAP_DROP_EXT(_id, _group_id, _metadata) \ argument 390 MLXSW_SP_TRAP_METADATA | (_metadata))
|