]> git.baikalelectronics.ru Git - kernel.git/commit
bpf: selftests: Add bind retry for post_bind{4, 6}
authorMenglong Dong <imagedong@tencent.com>
Thu, 6 Jan 2022 13:20:22 +0000 (21:20 +0800)
committerAlexei Starovoitov <ast@kernel.org>
Fri, 7 Jan 2022 01:08:35 +0000 (17:08 -0800)
commita9e4e9f55988e0e8521d720be6486f173469568f
tree1ec517c9838222412ef4540d32f05bfcc52e14ec
parent03d0e85c8a18765f96e8958c4882d9040a8f8b8b
bpf: selftests: Add bind retry for post_bind{4, 6}

With previous patch, kernel is able to 'put_port' after sys_bind()
fails. Add the test for that case: rebind another port after
sys_bind() fails. If the bind success, it means previous bind
operation is already undoed.

Signed-off-by: Menglong Dong <imagedong@tencent.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20220106132022.3470772-4-imagedong@tencent.com
tools/testing/selftests/bpf/test_sock.c