Home
last modified time | relevance | path

Searched refs:SO_REUSEPORT (Results 1 – 25 of 38) sorted by relevance

12

/linux/tools/testing/selftests/bpf/progs/
H A Dbind6_prog.c70 if (bpf_setsockopt(ctx, SOL_SOCKET, SO_REUSEPORT, in bind_reuseport()
73 if (bpf_getsockopt(ctx, SOL_SOCKET, SO_REUSEPORT, in bind_reuseport()
77 if (bpf_setsockopt(ctx, SOL_SOCKET, SO_REUSEPORT, in bind_reuseport()
80 if (bpf_getsockopt(ctx, SOL_SOCKET, SO_REUSEPORT, in bind_reuseport()
H A Dsetget_sockopt.c43 { .opt = SO_REUSEPORT, .flip = 1, },
/linux/tools/testing/selftests/net/
H A Dbind_bhash.c78 sock_fd = bind_socket(SO_REUSEADDR | SO_REUSEPORT, setup_addr); in setup()
106 listener_fd = bind_socket(SO_REUSEADDR | SO_REUSEPORT, setup_addr); in main()
H A Dreuseport_bpf.c2 * Test functionality of BPF filters for SO_REUSEPORT. The tests below will use
163 if (setsockopt(fd[i], SOL_SOCKET, SO_REUSEPORT, &opt, in build_recv_group()
165 error(1, errno, "failed to set SO_REUSEPORT on %d", i); in build_recv_group()
320 if (setsockopt(fd1, SOL_SOCKET, SO_REUSEPORT, &opt, sizeof(opt))) in test_extra_filter()
321 error(1, errno, "failed to set SO_REUSEPORT on socket 1"); in test_extra_filter()
322 if (setsockopt(fd2, SOL_SOCKET, SO_REUSEPORT, &opt, sizeof(opt))) in test_extra_filter()
323 error(1, errno, "failed to set SO_REUSEPORT on socket 2"); in test_extra_filter()
351 fprintf(stderr, "Testing filters on non-SO_REUSEPORT socket...\n"); in test_filter_no_reuseport()
399 if (setsockopt(fd1, SOL_SOCKET, SO_REUSEPORT, &opt, sizeof(opt))) in test_filter_without_bind()
400 error(1, errno, "failed to set SO_REUSEPORT o in test_filter_without_bind()
[all...]
H A Dstress_reuseport_listen.c7 * SO_REUSEPORT.
50 err = setsockopt(*cur_fd, SOL_SOCKET, SO_REUSEPORT, in bind_reuseport_sock6()
54 "setsockopt(lfds[%u,%u], SO_REUSEPORT)", in bind_reuseport_sock6()
H A Dreuseaddr_ports_exhausted.c11 * 4. if SO_REUSEADDR is enabled and SO_REUSEPORT is disabled,
13 * 5. if SO_REUSEADDR and SO_REUSEPORT are enabled and
66 ret = setsockopt(fd, SOL_SOCKET, SO_REUSEPORT, &reuseport, sizeof(int)); in bind_port()
67 ASSERT_EQ(0, ret) TH_LOG("failed to setsockopt: SO_REUSEPORT."); in bind_port()
H A Dfin_ack_lat.c125 if (setsockopt(sock, SOL_SOCKET, SO_REUSEADDR | SO_REUSEPORT, in main()
H A Dreuseport_dualstack.c3 * It is possible to use SO_REUSEPORT to open multiple sockets bound to
8 * the original SO_REUSEPORT implementation, but broke with
61 if (setsockopt(rcv_fds[i], SOL_SOCKET, SO_REUSEPORT, &opt, in build_rcv_fd()
63 error(1, errno, "failed to set SO_REUSEPORT"); in build_rcv_fd()
H A Dreuseport_addr_any.c75 if (setsockopt(rcv_fds[i], SOL_SOCKET, SO_REUSEPORT, &opt, in build_rcv_fd()
77 error(1, errno, "failed to set SO_REUSEPORT"); in build_rcv_fd()
H A Dso_incoming_cpu.c136 ret = setsockopt(fd, SOL_SOCKET, SO_REUSEPORT, &(int){1}, sizeof(int)); in create_server()
H A Dreuseport_bpf_numa.c3 * Test functionality of BPF filters with SO_REUSEPORT. Same test as
61 if (setsockopt(rcv_fd[i], SOL_SOCKET, SO_REUSEPORT, &opt, in build_rcv_group()
63 error(1, errno, "failed to set SO_REUSEPORT"); in build_rcv_group()
H A Dreuseport_bpf_cpu.c3 * Test functionality of BPF filters with SO_REUSEPORT. This program creates
4 * an SO_REUSEPORT receiver group containing one socket per CPU core. It then
65 if (setsockopt(rcv_fd[i], SOL_SOCKET, SO_REUSEPORT, &opt, in build_rcv_group()
67 error(1, errno, "failed to set SO_REUSEPORT"); in build_rcv_group()
H A Dudpgso_bench_rx.c138 if (setsockopt(fd, SOL_SOCKET, SO_REUSEPORT, &val, sizeof(val))) in do_socket()
H A Dtcp_fastopen_backup_key.c10 * to the same port via SO_REUSEPORT. This simulates key rotation
127 if (setsockopt(rcv_fds[i], SOL_SOCKET, SO_REUSEPORT, &opt, in build_rcv_fd()
129 error(1, errno, "failed to set SO_REUSEPORT"); in build_rcv_fd()
/linux/arch/sparc/include/uapi/asm/
H A Dsocket.h20 #define SO_REUSEPORT 0x0200 macro
/linux/tools/testing/selftests/net/netfilter/
H A Dconnect_close.c59 setsockopt(s, SOL_SOCKET, SO_REUSEPORT, &one, sizeof(one)); in do_accept()
/linux/tools/include/uapi/asm-generic/
H A Dsocket.h27 #define SO_REUSEPORT 15 macro
/linux/include/uapi/asm-generic/
H A Dsocket.h27 #define SO_REUSEPORT 15 macro
/linux/arch/alpha/include/uapi/asm/
H A Dsocket.h24 #define SO_REUSEPORT 0x0200 macro
/linux/arch/parisc/include/uapi/asm/
H A Dsocket.h18 #define SO_REUSEPORT 0x0200 macro
/linux/Documentation/translations/zh_CN/networking/
H A Dnapi.rst233 或者,如果应用程序使用 SO_REUSEPORT,可以插入 bpf 或 ebpf 程序来分发传入连接,使得每个
/linux/tools/testing/selftests/bpf/prog_tests/
H A Dsocket_helpers.h218 err = xsetsockopt(s, SOL_SOCKET, SO_REUSEPORT, &one, sizeof(one)); in enable_reuseport()
H A Dmigrate_reuseport.c234 SO_REUSEPORT, &reuseport, sizeof(reuseport)); in start_servers()
235 if (!ASSERT_OK(err, "setsockopt - SO_REUSEPORT")) in start_servers()
/linux/tools/testing/selftests/bpf/benchs/
H A Dbench_sockmap.c201 err = setsockopt(ctx.sfd, SOL_SOCKET, SO_REUSEPORT, &one, sizeof(one)); in create_sockets()
/linux/net/mptcp/
H A Dsockopt.c298 case SO_REUSEPORT: in mptcp_setsockopt_sol_socket()
311 if (optname == SO_REUSEPORT) in mptcp_setsockopt_sol_socket()

12