• Home
  • Raw
  • Download

Lines Matching refs:fds

221 static int sock_fanout_read(int fds[], char *rings[], const int expect[])  in sock_fanout_read()  argument
225 ret[0] = sock_fanout_read_ring(fds[0], rings[0]); in sock_fanout_read()
226 ret[1] = sock_fanout_read_ring(fds[1], rings[1]); in sock_fanout_read()
255 int fds[2]; in test_control_group() local
259 fds[0] = sock_fanout_open(PACKET_FANOUT_HASH, 0); in test_control_group()
260 if (fds[0] == -1) { in test_control_group()
278 fds[1] = sock_fanout_open(PACKET_FANOUT_HASH, 0); in test_control_group()
279 if (fds[1] == -1) { in test_control_group()
283 if (close(fds[1]) || close(fds[0])) { in test_control_group()
292 int fds[3]; in test_unique_fanout_group_ids() local
297 fds[0] = sock_fanout_open(PACKET_FANOUT_HASH | in test_unique_fanout_group_ids()
299 if (fds[0] == -1) { in test_unique_fanout_group_ids()
304 sock_fanout_getopts(fds[0], &typeflags, &first_group_id); in test_unique_fanout_group_ids()
315 fds[1] = sock_fanout_open(PACKET_FANOUT_HASH, first_group_id); in test_unique_fanout_group_ids()
316 if (fds[1] == -1) { in test_unique_fanout_group_ids()
322 fds[2] = sock_fanout_open(PACKET_FANOUT_HASH | in test_unique_fanout_group_ids()
324 if (fds[2] == -1) { in test_unique_fanout_group_ids()
330 sock_fanout_getopts(fds[2], &typeflags, &second_group_id); in test_unique_fanout_group_ids()
338 if (close(fds[0]) || close(fds[1]) || close(fds[2])) { in test_unique_fanout_group_ids()
350 int fds[2], fds_udp[2][2], ret; in test_datapath() local
356 fds[0] = sock_fanout_open(typeflags, 0); in test_datapath()
357 fds[1] = sock_fanout_open(typeflags, 0); in test_datapath()
358 if (fds[0] == -1 || fds[1] == -1) { in test_datapath()
363 sock_fanout_set_cbpf(fds[0]); in test_datapath()
365 sock_fanout_set_ebpf(fds[0]); in test_datapath()
367 rings[0] = sock_fanout_open_ring(fds[0]); in test_datapath()
368 rings[1] = sock_fanout_open_ring(fds[1]); in test_datapath()
371 sock_fanout_read(fds, rings, expect0); in test_datapath()
376 ret = sock_fanout_read(fds, rings, expect1); in test_datapath()
381 ret |= sock_fanout_read(fds, rings, expect2); in test_datapath()
390 close(fds[1]) || close(fds[0])) { in test_datapath()