net: add sock_set_reuseaddr
authorChristoph Hellwig <hch@lst.de>
Thu, 28 May 2020 05:12:09 +0000 (07:12 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 28 May 2020 18:11:44 +0000 (11:11 -0700)
commitb58f0e8f38c0a44afa59601a115bd231f23471e1
tree591622253553216fe2635b360b4f31a62636226b
parent1eba1110f0a7a2faa88b8bd1fc5516870bda387b
net: add sock_set_reuseaddr

Add a helper to directly set the SO_REUSEADDR sockopt from kernel space
without going through a fake uaccess.

For this the iscsi target now has to formally depend on inet to avoid
a mostly theoretical compile failure.  For actual operation it already
did depend on having ipv4 or ipv6 support.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Acked-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/infiniband/sw/siw/siw_cm.c
drivers/nvme/target/tcp.c
drivers/target/iscsi/Kconfig
drivers/target/iscsi/iscsi_target_login.c
fs/dlm/lowcomms.c
include/net/sock.h
net/core/sock.c