Lines Matching refs:rcv_fds
34 static void build_rcv_fd(int family, int proto, int *rcv_fds, int count, in build_rcv_fd() argument
75 rcv_fds[i] = socket(family, proto, 0); in build_rcv_fd()
76 if (rcv_fds[i] < 0) in build_rcv_fd()
80 if (setsockopt(rcv_fds[i], SOL_SOCKET, SO_REUSEPORT, &opt, in build_rcv_fd()
84 if (bind(rcv_fds[i], addr, sz)) in build_rcv_fd()
87 if (proto == SOCK_STREAM && listen(rcv_fds[i], 10)) in build_rcv_fd()
90 if (setsockopt(rcv_fds[i], SOL_DCCP, in build_rcv_fd()
95 if (listen(rcv_fds[i], 10)) in build_rcv_fd()
194 static void test(int *rcv_fds, int count, int family, int proto, int fd) in test() argument
205 ev.data.fd = rcv_fds[i]; in test()
206 if (epoll_ctl(epfd, EPOLL_CTL_ADD, rcv_fds[i], &ev)) in test()
231 int rcv_fds[10], i; in run_one_test() local
233 build_rcv_fd(AF_INET, proto, rcv_fds, 2, NULL); in run_one_test()
234 build_rcv_fd(AF_INET6, proto, rcv_fds + 2, 2, NULL); in run_one_test()
235 build_rcv_fd(fam_rcv, proto, rcv_fds + 4, 1, addr_str); in run_one_test()
236 build_rcv_fd(AF_INET, proto, rcv_fds + 5, 2, NULL); in run_one_test()
237 build_rcv_fd(AF_INET6, proto, rcv_fds + 7, 2, NULL); in run_one_test()
238 test(rcv_fds, 9, fam_send, proto, rcv_fds[4]); in run_one_test()
240 close(rcv_fds[i]); in run_one_test()