summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@primarydata.com>2015-02-10 01:20:14 +0300
committerTrond Myklebust <trond.myklebust@primarydata.com>2015-02-10 01:31:02 +0300
commit402e23b4ed9ed81852b6c15b793fcf84ea91e491 (patch)
treeb0f32d653bd465bb627b551aeaa6f411b914dedc /net
parent54c09874929dcaac37ed62ad2eca45d960ba1a00 (diff)
downloadlinux-402e23b4ed9ed81852b6c15b793fcf84ea91e491.tar.xz
SUNRPC: Fix stupid typo in xs_sock_set_reuseport
Yes, kernel_setsockopt() hates you for using a char argument. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'net')
-rw-r--r--net/sunrpc/xprtsock.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/net/sunrpc/xprtsock.c b/net/sunrpc/xprtsock.c
index 8ab02262c761..19f7526f8965 100644
--- a/net/sunrpc/xprtsock.c
+++ b/net/sunrpc/xprtsock.c
@@ -1629,9 +1629,10 @@ static unsigned short xs_get_random_port(void)
*/
static void xs_sock_set_reuseport(struct socket *sock)
{
- char opt = 1;
+ int opt = 1;
- kernel_setsockopt(sock, SOL_SOCKET, SO_REUSEPORT, &opt, sizeof(opt));
+ kernel_setsockopt(sock, SOL_SOCKET, SO_REUSEPORT,
+ (char *)&opt, sizeof(opt));
}
static unsigned short xs_sock_getport(struct socket *sock)