diff options
| author | Geliang Tang <[email protected]> | 2024-05-05 11:35:10 +0000 |
|---|---|---|
| committer | Martin KaFai Lau <[email protected]> | 2024-05-09 20:40:38 +0000 |
| commit | 49e1fa8dbd81340f610057be3f3909f24c232807 (patch) | |
| tree | fc50583586dff003832a56fa604d97e424694266 /tools/testing/selftests/bpf/prog_tests/sockopt_inherit.c | |
| parent | selftests/bpf: Use start_server_addr in sockopt_inherit (diff) | |
| download | kernel-49e1fa8dbd81340f610057be3f3909f24c232807.tar.gz kernel-49e1fa8dbd81340f610057be3f3909f24c232807.zip | |
selftests/bpf: Use start_server_addr in test_tcp_check_syncookie
Include network_helpers.h in test_tcp_check_syncookie_user.c, use
public helper start_server_addr() in it instead of the local defined
function start_server(). This can avoid duplicate code.
Add two helpers v6only_true() and v6only_false() to set IPV6_V6ONLY
sockopt to true or false, set them to post_socket_cb pointer of struct
network_helper_opts, and pass it to start_server_setsockopt().
In order to use functions defined in network_helpers.c, Makefile needs
to be updated too.
Signed-off-by: Geliang Tang <[email protected]>
Link: https://lore.kernel.org/r/e0c5324f5da84f453f47543536e70f126eaa8678.1714907662.git.tanggeliang@kylinos.cn
Signed-off-by: Martin KaFai Lau <[email protected]>
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/sockopt_inherit.c')
0 files changed, 0 insertions, 0 deletions
