aboutsummaryrefslogtreecommitdiffstats
path: root/net/core/sock.c
diff options
context:
space:
mode:
authorChristoph Hellwig <[email protected]>2020-07-23 06:09:07 +0000
committerDavid S. Miller <[email protected]>2020-07-24 22:41:54 +0000
commita7b75c5a8c41445f33efb663887ff5f5c3b4454b (patch)
treea87e011ba3a0d76fda030b3a62080caa97fae1ef /net/core/sock.c
parentnet/tcp: switch do_tcp_setsockopt to sockptr_t (diff)
downloadkernel-a7b75c5a8c41445f33efb663887ff5f5c3b4454b.tar.gz
kernel-a7b75c5a8c41445f33efb663887ff5f5c3b4454b.zip
net: pass a sockptr_t into ->setsockopt
Rework the remaining setsockopt code to pass a sockptr_t instead of a plain user pointer. This removes the last remaining set_fs(KERNEL_DS) outside of architecture specific code. Signed-off-by: Christoph Hellwig <[email protected]> Acked-by: Stefan Schmidt <[email protected]> [ieee802154] Acked-by: Matthieu Baerts <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'net/core/sock.c')
-rw-r--r--net/core/sock.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/core/sock.c b/net/core/sock.c
index 1444d7d53ba2..2c5dd1397775 100644
--- a/net/core/sock.c
+++ b/net/core/sock.c
@@ -3211,7 +3211,7 @@ EXPORT_SYMBOL(sock_common_recvmsg);
* Set socket options on an inet socket.
*/
int sock_common_setsockopt(struct socket *sock, int level, int optname,
- char __user *optval, unsigned int optlen)
+ sockptr_t optval, unsigned int optlen)
{
struct sock *sk = sock->sk;