diff options
| author | Geliang Tang <[email protected]> | 2024-07-18 06:22:29 +0000 |
|---|---|---|
| committer | Andrii Nakryiko <[email protected]> | 2024-07-29 19:52:24 +0000 |
| commit | a63507f3b11de30fd7711ec244fe354fb4a01a09 (patch) | |
| tree | a23b7388669035267777cf0d6127ff2c7a92965a /tools/testing/selftests/bpf/prog_tests/bpf_tcp_ca.c | |
| parent | Merge tag 'net-6.11-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/net... (diff) | |
| download | kernel-a63507f3b11de30fd7711ec244fe354fb4a01a09.tar.gz kernel-a63507f3b11de30fd7711ec244fe354fb4a01a09.zip | |
selftests/bpf: Drop type of connect_to_fd_opts
The "type" parameter of connect_to_fd_opts() is redundant of "server_fd".
Since the "type" can be obtained inside by invoking getsockopt(SO_TYPE),
without passing it in as a parameter.
This patch drops the "type" parameter of connect_to_fd_opts() and updates
its callers.
Suggested-by: Martin KaFai Lau <[email protected]>
Signed-off-by: Geliang Tang <[email protected]>
Link: https://lore.kernel.org/r/50d8ce7ab7ab0c0f4d211fc7cc4ebe3d3f63424c.1721282219.git.tanggeliang@kylinos.cn
Signed-off-by: Martin KaFai Lau <[email protected]>
Signed-off-by: Andrii Nakryiko <[email protected]>
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/bpf_tcp_ca.c')
| -rw-r--r-- | tools/testing/selftests/bpf/prog_tests/bpf_tcp_ca.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/selftests/bpf/prog_tests/bpf_tcp_ca.c b/tools/testing/selftests/bpf/prog_tests/bpf_tcp_ca.c index 63422f4f3896..1d494b4453f4 100644 --- a/tools/testing/selftests/bpf/prog_tests/bpf_tcp_ca.c +++ b/tools/testing/selftests/bpf/prog_tests/bpf_tcp_ca.c @@ -49,7 +49,7 @@ static bool start_test(char *addr_str, goto err; /* connect to server */ - *cli_fd = connect_to_fd_opts(*srv_fd, SOCK_STREAM, cli_opts); + *cli_fd = connect_to_fd_opts(*srv_fd, cli_opts); if (!ASSERT_NEQ(*cli_fd, -1, "connect_to_fd_opts")) goto err; |
