Searched refs:pollfds (Results 1 – 4 of 4) sorted by relevance
/Zephyr-latest/tests/net/socket/poll/src/ |
D | main.c | 43 struct zsock_pollfd pollfds[2]; in ZTEST() local 60 memset(pollfds, 0, sizeof(pollfds)); in ZTEST() 61 pollfds[0].fd = c_sock; in ZTEST() 62 pollfds[0].events = ZSOCK_POLLIN; in ZTEST() 63 pollfds[1].fd = s_sock; in ZTEST() 64 pollfds[1].events = ZSOCK_POLLIN; in ZTEST() 68 res = zsock_poll(pollfds, ARRAY_SIZE(pollfds), 0); in ZTEST() 72 zassert_equal(pollfds[0].fd, c_sock, ""); in ZTEST() 73 zassert_equal(pollfds[0].events, ZSOCK_POLLIN, ""); in ZTEST() 74 zassert_equal(pollfds[0].revents, 0, ""); in ZTEST() [all …]
|
/Zephyr-latest/samples/net/sockets/echo_async/src/ |
D | socket_echo.c | 47 struct pollfd pollfds[NUM_FDS]; variable 84 if (pollfds[i].fd < 0) { in pollfds_add() 93 pollfds[i].fd = fd; in pollfds_add() 94 pollfds[i].events = POLLIN; in pollfds_add() 102 if (pollfds[i].fd == fd) { in pollfds_del() 103 pollfds[i].fd = -1; in pollfds_del() 189 res = poll(pollfds, pollnum, -1); in main() 196 if (!(pollfds[i].revents & POLLIN)) { in main() 199 int fd = pollfds[i].fd; in main()
|
/Zephyr-latest/modules/thrift/src/thrift/server/ |
D | TFDServer.cpp | 55 array<pollfd, 2> pollfds = { in read_virt() local 72 r = poll(&pollfds.front(), pollfds.size(), -1); in read_virt() 83 for (auto &pfd : pollfds) { in read_virt() 90 if (pollfds[0].revents & POLLIN) { in read_virt() 102 __ASSERT_NO_MSG(pollfds[1].revents & POLLIN); in read_virt()
|
/Zephyr-latest/tests/net/socket/getaddrinfo/src/ |
D | main.c | 113 struct zsock_pollfd pollfds[2]; in process_dns() local 124 memset(pollfds, 0, sizeof(pollfds)); in process_dns() 125 pollfds[0].fd = sock_v4; in process_dns() 126 pollfds[0].events = ZSOCK_POLLIN; in process_dns() 127 pollfds[1].fd = sock_v6; in process_dns() 128 pollfds[1].events = ZSOCK_POLLIN; in process_dns() 132 ret = zsock_poll(pollfds, ARRAY_SIZE(pollfds), -1); in process_dns() 137 for (idx = 0; idx < ARRAY_SIZE(pollfds); idx++) { in process_dns() 138 if (pollfds[idx].revents & ZSOCK_POLLIN) { in process_dns() 139 if (pollfds[idx].fd == sock_v4) { in process_dns() [all …]
|