Home
last modified time | relevance | path

Searched refs:cli_fd (Results 1 – 5 of 5) sorted by relevance

/Linux-v5.15/tools/testing/selftests/bpf/prog_tests/
Dtcpbpf_user.c53 int listen_fd = -1, cli_fd = -1, accept_fd = -1; in run_test() local
63 cli_fd = connect_to_fd(listen_fd, 0); in run_test()
64 if (CHECK(cli_fd == -1, "connect_to_fd(listen_fd)", in run_test()
65 "cli_fd:%d errno:%d\n", cli_fd, errno)) in run_test()
77 rv = send(cli_fd, buf, 1000, 0); in run_test()
93 rv = recv(cli_fd, buf, 500, 0); in run_test()
102 err = recv(cli_fd, buf, 1, 0); in run_test()
106 shutdown(cli_fd, SHUT_WR); in run_test()
112 if (cli_fd != -1) in run_test()
113 close(cli_fd); in run_test()
Dbtf_skc_cls_ingress.c93 int listen_fd = -1, cli_fd = -1, err; in test_conn() local
111 cli_fd = connect_to_fd(listen_fd, 0); in test_conn()
112 if (CHECK_FAIL(cli_fd == -1)) in test_conn()
135 if (cli_fd != -1) in test_conn()
136 close(cli_fd); in test_conn()
141 int listen_fd = -1, cli_fd = -1, err; in test_syncookie() local
160 cli_fd = connect_to_fd(listen_fd, 0); in test_syncookie()
161 if (CHECK_FAIL(cli_fd == -1)) in test_syncookie()
189 if (cli_fd != -1) in test_syncookie()
190 close(cli_fd); in test_syncookie()
Dsock_fields.c196 static void check_sk_pkt_out_cnt(int accept_fd, int cli_fd) in check_sk_pkt_out_cnt() argument
221 err = bpf_map_lookup_elem(sk_pkt_out_cnt_fd, &cli_fd, &pkt_out_cnt); in check_sk_pkt_out_cnt()
223 err = bpf_map_lookup_elem(sk_pkt_out_cnt10_fd, &cli_fd, in check_sk_pkt_out_cnt()
261 int listen_fd = -1, cli_fd = -1, accept_fd = -1, err, i; in test() local
277 cli_fd = connect_to_fd(listen_fd, 0); in test()
278 if (CHECK_FAIL(cli_fd == -1)) in test()
281 err = getsockname(cli_fd, (struct sockaddr *)&cli_sa6, &addrlen); in test()
304 err = recv(cli_fd, buf, DATA_LEN, 0); in test()
310 shutdown(cli_fd, SHUT_WR); in test()
316 err = recv(cli_fd, buf, 1, 0); in test()
[all …]
Dbpf_tcp_ca.c257 int err, lfd = -1, cli_fd = -1, srv_fd = -1; in test_dctcp_fallback() local
282 cli_fd = connect_to_fd_opts(lfd, &opts); in test_dctcp_fallback()
283 if (!ASSERT_GE(cli_fd, 0, "cli_fd")) in test_dctcp_fallback()
304 if (cli_fd != -1) in test_dctcp_fallback()
305 close(cli_fd); in test_dctcp_fallback()
Dselect_reuseport.c248 int cli_fd) in check_data() argument
256 err = getsockname(cli_fd, (struct sockaddr *)&cli_sa, in check_data()
409 int nev, srv_fd, cli_fd; in do_test() local
414 cli_fd = send_data(type, family, cmd, cmd ? sizeof(*cmd) : 0, in do_test()
416 if (cli_fd < 0) in do_test()
427 check_data(type, family, cmd, cli_fd); in do_test()
461 close(cli_fd); in do_test()
556 int cli_fd, err, nev; in test_detach_bpf() local
578 cli_fd = send_data(type, family, &cmd, sizeof(cmd), PASS); in test_detach_bpf()
579 if (cli_fd < 0) in test_detach_bpf()
[all …]