summaryrefslogtreecommitdiffstats
path: root/net/rds/send.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2014-11-20 09:31:08 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2014-11-24 05:16:43 -0500
commit083735f4b01b703184c0e11c2e384b2c60a8aea4 (patch)
treeac816d0abd837948fb6e6c54cdf680e5def4923c /net/rds/send.c
parentc310e72c89926e06138e4881f21e4c8da3e7ef18 (diff)
downloadop-kernel-dev-083735f4b01b703184c0e11c2e384b2c60a8aea4.zip
op-kernel-dev-083735f4b01b703184c0e11c2e384b2c60a8aea4.tar.gz
rds: switch rds_message_copy_from_user() to iov_iter
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'net/rds/send.c')
-rw-r--r--net/rds/send.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/rds/send.c b/net/rds/send.c
index 0a64541..4de62ea 100644
--- a/net/rds/send.c
+++ b/net/rds/send.c
@@ -934,7 +934,9 @@ int rds_sendmsg(struct kiocb *iocb, struct socket *sock, struct msghdr *msg,
int queued = 0, allocated_mr = 0;
int nonblock = msg->msg_flags & MSG_DONTWAIT;
long timeo = sock_sndtimeo(sk, nonblock);
+ struct iov_iter from;
+ iov_iter_init(&from, WRITE, msg->msg_iov, msg->msg_iovlen, payload_len);
/* Mirror Linux UDP mirror of BSD error message compatibility */
/* XXX: Perhaps MSG_MORE someday */
if (msg->msg_flags & ~(MSG_DONTWAIT | MSG_CMSG_COMPAT)) {
@@ -982,7 +984,7 @@ int rds_sendmsg(struct kiocb *iocb, struct socket *sock, struct msghdr *msg,
ret = -ENOMEM;
goto out;
}
- ret = rds_message_copy_from_user(rm, msg->msg_iov, payload_len);
+ ret = rds_message_copy_from_user(rm, &from);
if (ret)
goto out;
}
OpenPOWER on IntegriCloud