]> git.baikalelectronics.ru Git - kernel.git/commit
net: Make locking in sock_bindtoindex optional
authorFerenc Fejes <fejes@inf.elte.hu>
Sat, 30 May 2020 21:09:00 +0000 (23:09 +0200)
committerAlexei Starovoitov <ast@kernel.org>
Mon, 1 Jun 2020 21:57:14 +0000 (14:57 -0700)
commitb1318d47958dea5beeee1ae4d28db528080d3985
treedc158cbccc05c8a068e015ada9d29d4f0a9d42c4
parentd6ddc0b3b95e17dd59aed8459789be9852e92202
net: Make locking in sock_bindtoindex optional

The sock_bindtoindex intended for kernel wide usage however
it will lock the socket regardless of the context. This modification
relax this behavior optionally: locking the socket will be optional
by calling the sock_bindtoindex with lock_sk = true.

The modification applied to all users of the sock_bindtoindex.

Signed-off-by: Ferenc Fejes <fejes@inf.elte.hu>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/bee6355da40d9e991b2f2d12b67d55ebb5f5b207.1590871065.git.fejes@inf.elte.hu
include/net/sock.h
net/core/sock.c
net/ipv4/udp_tunnel.c
net/ipv6/ip6_udp_tunnel.c