]> git.proxmox.com Git - mirror_ubuntu-hirsute-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)
commit8ea204c2b658eaef55b4716fde469fb66c589a3d
treedc158cbccc05c8a068e015ada9d29d4f0a9d42c4
parentbb2359f4dbe98e8863b4e885fc09269ef4682ec3
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