Searched refs:src_fd (Results 1 – 6 of 6) sorted by relevance
/tools/testing/selftests/filesystems/fuse/ |
D | fuse_test.c | 206 int src_fd = -1; in bpf_test_real() local 213 TEST(src_fd = open(ft_src, O_DIRECTORY | O_RDONLY | O_CLOEXEC), in bpf_test_real() 214 src_fd != -1); in bpf_test_real() 215 TEST(fd = openat(src_fd, test_name, O_CREAT | O_RDWR | O_CLOEXEC, 0777), in bpf_test_real() 223 TESTEQUAL(mount_fuse(mount_dir, bpf_fd, src_fd, &fuse_dev), 0); in bpf_test_real() 238 close(src_fd); in bpf_test_real() 249 int src_fd = -1; in bpf_test_partial() local 255 TEST(src_fd = open(ft_src, O_DIRECTORY | O_RDONLY | O_CLOEXEC), in bpf_test_partial() 256 src_fd != -1); in bpf_test_partial() 257 TESTEQUAL(create_file(src_fd, s(test_name), 1, 2), 0); in bpf_test_partial() [all …]
|
D | fuse_daemon.c | 202 int src_fd = -1; in main() local 222 TEST(src_fd = open("fd-src", O_DIRECTORY | O_RDONLY | O_CLOEXEC), in main() 223 src_fd != -1); in main() 224 TESTSYSCALL(mkdirat(src_fd, "show", 0777)); in main() 225 TESTSYSCALL(mkdirat(src_fd, "hide", 0777)); in main() 241 TESTEQUAL(mount_fuse(mount_dir, bpf_fd, src_fd, &fuse_dev), 0); in main()
|
/tools/testing/selftests/bpf/prog_tests/ |
D | sockmap_basic.c | 62 int err, src_fd, dst_fd; in compare_cookies() local 64 src_fd = bpf_map__fd(src); in compare_cookies() 70 err = bpf_map_lookup_elem(src_fd, &i, &src_cookie); in compare_cookies() 193 int err, len, src_fd, iter_fd; in test_sockmap_copy() local 223 src_fd = bpf_map__fd(src); in test_sockmap_copy() 230 err = bpf_map_update_elem(src_fd, &i, &sock_fd[i], BPF_NOEXIST); in test_sockmap_copy() 235 linfo.map.map_fd = src_fd; in test_sockmap_copy()
|
D | tc_redirect.c | 1054 static int tun_relay_loop(int src_fd, int target_fd) in tun_relay_loop() argument 1065 FD_SET(src_fd, &rfds); in tun_relay_loop() 1068 if (select(1 + MAX(src_fd, target_fd), &rfds, NULL, NULL, NULL) < 0) { in tun_relay_loop() 1073 direction = FD_ISSET(src_fd, &rfds) ? SRC_TO_TARGET : TARGET_TO_SRC; in tun_relay_loop() 1075 nread = read(direction == SRC_TO_TARGET ? src_fd : target_fd, buf, sizeof(buf)); in tun_relay_loop() 1081 nwrite = write(direction == SRC_TO_TARGET ? target_fd : src_fd, buf, nread); in tun_relay_loop() 1097 int src_fd, target_fd = -1; in test_tc_redirect_peer_l3() local 1111 src_fd = tun_open("tun_src"); in test_tc_redirect_peer_l3() 1112 if (!ASSERT_GE(src_fd, 0, "tun_open tun_src")) in test_tc_redirect_peer_l3() 1130 exit(tun_relay_loop(src_fd, target_fd)); in test_tc_redirect_peer_l3() [all …]
|
/tools/include/uapi/linux/ |
D | fs.h | 55 __s64 src_fd; member
|
/tools/testing/selftests/landlock/ |
D | fs_test.c | 1821 int dst_fd, src_fd; in copy_binary() local 1829 src_fd = open(BINARY_PATH, O_RDONLY | O_CLOEXEC); in copy_binary() 1830 ASSERT_LE(0, src_fd) in copy_binary() 1835 ASSERT_EQ(0, fstat(src_fd, &statbuf)); in copy_binary() 1837 sendfile(dst_fd, src_fd, 0, statbuf.st_size)); in copy_binary() 1838 ASSERT_EQ(0, close(src_fd)); in copy_binary()
|