/linux/tools/testing/selftests/coredump/ |
H A D | stackdump_test.c | 298 int ipc_sockets[2]; in TEST_F() local 303 ret = socketpair(AF_UNIX, SOCK_STREAM | SOCK_CLOEXEC, 0, ipc_sockets); in TEST_F() 312 close(ipc_sockets[0]); in TEST_F() 318 if (write_nointr(ipc_sockets[1], "1", 1) < 0) in TEST_F() 321 close(ipc_sockets[1]); in TEST_F() 374 EXPECT_EQ(close(ipc_sockets[1]), 0); in TEST_F() 375 ASSERT_EQ(read_nointr(ipc_sockets[0], &c, 1), 1); in TEST_F() 376 EXPECT_EQ(close(ipc_sockets[0]), 0); in TEST_F() 407 int ipc_sockets[2]; in TEST_F() local 412 ret = socketpair(AF_UNIX, SOCK_STREAM | SOCK_CLOEXEC, 0, ipc_sockets); in TEST_F() 534 int ipc_sockets[2]; TEST_F() local 736 int ipc_sockets[2]; TEST_F() local 860 int ipc_sockets[2]; TEST_F() local 973 int ipc_sockets[2]; TEST_F() local 1086 int ipc_sockets[2]; TEST_F() local 1184 int ipc_sockets[2]; TEST_F() local 1281 int ipc_sockets[2]; TEST_F() local 1380 int ipc_sockets[2]; TEST_F() local 1486 int ipc_sockets[2]; global() variable 1699 int ipc_sockets[2]; global() variable [all...] |
/linux/tools/testing/selftests/pidfd/ |
H A D | pidfd_info_test.c | 44 int ipc_sockets[2]; in FIXTURE_SETUP() local 47 ret = socketpair(AF_LOCAL, SOCK_STREAM | SOCK_CLOEXEC, 0, ipc_sockets); in FIXTURE_SETUP() 54 close(ipc_sockets[0]); in FIXTURE_SETUP() 56 if (write_nointr(ipc_sockets[1], "1", 1) < 0) in FIXTURE_SETUP() 59 close(ipc_sockets[1]); in FIXTURE_SETUP() 65 EXPECT_EQ(close(ipc_sockets[1]), 0); in FIXTURE_SETUP() 66 ASSERT_EQ(read_nointr(ipc_sockets[0], &c, 1), 1); in FIXTURE_SETUP() 67 EXPECT_EQ(close(ipc_sockets[0]), 0); in FIXTURE_SETUP() 72 ret = socketpair(AF_LOCAL, SOCK_STREAM | SOCK_CLOEXEC, 0, ipc_sockets); in FIXTURE_SETUP() 79 close(ipc_sockets[ in FIXTURE_SETUP() 242 int ipc_sockets[2]; TEST_F() local 420 int ipc_sockets[2]; TEST_F() local 569 int ipc_sockets[2]; TEST_F() local [all...] |
H A D | pidfd_file_handle_test.c | 43 int ipc_sockets[2]; in FIXTURE_SETUP() local 50 ret = socketpair(AF_LOCAL, SOCK_STREAM | SOCK_CLOEXEC, 0, ipc_sockets); in FIXTURE_SETUP() 57 close(ipc_sockets[0]); in FIXTURE_SETUP() 59 if (write_nointr(ipc_sockets[1], "1", 1) < 0) in FIXTURE_SETUP() 62 close(ipc_sockets[1]); in FIXTURE_SETUP() 68 close(ipc_sockets[1]); in FIXTURE_SETUP() 69 ASSERT_EQ(read_nointr(ipc_sockets[0], &c, 1), 1); in FIXTURE_SETUP() 70 close(ipc_sockets[0]); in FIXTURE_SETUP() 72 ret = socketpair(AF_LOCAL, SOCK_STREAM | SOCK_CLOEXEC, 0, ipc_sockets); in FIXTURE_SETUP() 79 close(ipc_sockets[ in FIXTURE_SETUP() [all...] |
H A D | pidfd_setns_test.c | 94 int ipc_sockets[2]; in FIXTURE_SETUP() local 155 ret = socketpair(AF_LOCAL, SOCK_STREAM | SOCK_CLOEXEC, 0, ipc_sockets); in FIXTURE_SETUP() 170 close(ipc_sockets[0]); in FIXTURE_SETUP() 197 if (write_nointr(ipc_sockets[1], "1", 1) < 0) in FIXTURE_SETUP() 200 close(ipc_sockets[1]); in FIXTURE_SETUP() 206 close(ipc_sockets[1]); in FIXTURE_SETUP() 207 ASSERT_EQ(read_nointr(ipc_sockets[0], &c, 1), 1); in FIXTURE_SETUP() 208 close(ipc_sockets[0]); in FIXTURE_SETUP() 210 ret = socketpair(AF_LOCAL, SOCK_STREAM | SOCK_CLOEXEC, 0, ipc_sockets); in FIXTURE_SETUP() 224 close(ipc_sockets[ in FIXTURE_SETUP() [all...] |
/linux/tools/testing/selftests/filesystems/overlayfs/ |
H A D | set_layers_via_fds.c | 337 int ipc_sockets[2]; in TEST_F() local 347 ret = socketpair(AF_LOCAL, SOCK_STREAM | SOCK_CLOEXEC, 0, ipc_sockets); in TEST_F() 353 if (close(ipc_sockets[0])) { in TEST_F() 363 if (read_nointr(ipc_sockets[1], &c, 1) != 1) { in TEST_F() 368 if (close(ipc_sockets[1])) { in TEST_F() 381 ASSERT_EQ(close(ipc_sockets[1]), 0); in TEST_F() 419 ASSERT_EQ(write_nointr(ipc_sockets[0], "1", 1), 1); in TEST_F() 420 ASSERT_EQ(close(ipc_sockets[0]), 0); in TEST_F()
|