diff options
author | Stephen Rothwell <sfr@canb.auug.org.au> | 2017-12-21 08:40:38 +1100 |
---|---|---|
committer | Stephen Rothwell <sfr@canb.auug.org.au> | 2017-12-21 08:40:38 +1100 |
commit | 3471bd2095e7fe737eb7d8ea40c928dbd4a84380 (patch) | |
tree | 9c39800c86ba4a552eb12d6928eca9ed3604635b /net/netfilter/ipvs/ip_vs_sync.c | |
parent | 37662a70abcd76abf52d4bbe307649a1155525b5 (diff) | |
parent | b75cfa1913c2890afc90d8d34ba8a63d1b4ba2af (diff) |
Merge remote-tracking branch 'vfs/for-next'
Diffstat (limited to 'net/netfilter/ipvs/ip_vs_sync.c')
-rw-r--r-- | net/netfilter/ipvs/ip_vs_sync.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/net/netfilter/ipvs/ip_vs_sync.c b/net/netfilter/ipvs/ip_vs_sync.c index 9ee71cb276d7..fbaf3bd05b2e 100644 --- a/net/netfilter/ipvs/ip_vs_sync.c +++ b/net/netfilter/ipvs/ip_vs_sync.c @@ -1636,17 +1636,14 @@ static int ip_vs_receive(struct socket *sock, char *buffer, const size_t buflen) { struct msghdr msg = {NULL,}; - struct kvec iov; + struct kvec iov = {buffer, buflen}; int len; EnterFunction(7); /* Receive a packet */ - iov.iov_base = buffer; - iov.iov_len = (size_t)buflen; - - len = kernel_recvmsg(sock, &msg, &iov, 1, buflen, MSG_DONTWAIT); - + iov_iter_kvec(&msg.msg_iter, READ | ITER_KVEC, &iov, 1, buflen); + len = sock_recvmsg(sock, &msg, MSG_DONTWAIT); if (len < 0) return len; |