aboutsummaryrefslogtreecommitdiffstats
path: root/net/tipc
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2014-11-15 01:13:43 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2014-11-24 05:16:40 -0500
commit562640f3c3fb64fca24253868dab6e900e305c46 (patch)
treebc651658b7e8ad80620419c781abcde65fac423e /net/tipc
parente0eb093e794452791b0f932a0120f410f614ad82 (diff)
tipc_sendmsg(): pass msghdr instead of its ->msg_iov
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'net/tipc')
-rw-r--r--net/tipc/socket.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/net/tipc/socket.c b/net/tipc/socket.c
index e91809182c28..2d4b2fa7d628 100644
--- a/net/tipc/socket.c
+++ b/net/tipc/socket.c
@@ -700,7 +700,7 @@ static unsigned int tipc_poll(struct file *file, struct socket *sock,
700 * tipc_sendmcast - send multicast message 700 * tipc_sendmcast - send multicast message
701 * @sock: socket structure 701 * @sock: socket structure
702 * @seq: destination address 702 * @seq: destination address
703 * @iov: message data to send 703 * @msg: message to send
704 * @dsz: total length of message data 704 * @dsz: total length of message data
705 * @timeo: timeout to wait for wakeup 705 * @timeo: timeout to wait for wakeup
706 * 706 *
@@ -708,7 +708,7 @@ static unsigned int tipc_poll(struct file *file, struct socket *sock,
708 * Returns the number of bytes sent on success, or errno 708 * Returns the number of bytes sent on success, or errno
709 */ 709 */
710static int tipc_sendmcast(struct socket *sock, struct tipc_name_seq *seq, 710static int tipc_sendmcast(struct socket *sock, struct tipc_name_seq *seq,
711 struct iovec *iov, size_t dsz, long timeo) 711 struct msghdr *msg, size_t dsz, long timeo)
712{ 712{
713 struct sock *sk = sock->sk; 713 struct sock *sk = sock->sk;
714 struct tipc_msg *mhdr = &tipc_sk(sk)->phdr; 714 struct tipc_msg *mhdr = &tipc_sk(sk)->phdr;
@@ -727,7 +727,7 @@ static int tipc_sendmcast(struct socket *sock, struct tipc_name_seq *seq,
727 727
728new_mtu: 728new_mtu:
729 mtu = tipc_bclink_get_mtu(); 729 mtu = tipc_bclink_get_mtu();
730 rc = tipc_msg_build(mhdr, iov, 0, dsz, mtu, &buf); 730 rc = tipc_msg_build(mhdr, msg->msg_iov, 0, dsz, mtu, &buf);
731 if (unlikely(rc < 0)) 731 if (unlikely(rc < 0))
732 return rc; 732 return rc;
733 733
@@ -951,7 +951,7 @@ static int tipc_sendmsg(struct kiocb *iocb, struct socket *sock,
951 timeo = sock_sndtimeo(sk, m->msg_flags & MSG_DONTWAIT); 951 timeo = sock_sndtimeo(sk, m->msg_flags & MSG_DONTWAIT);
952 952
953 if (dest->addrtype == TIPC_ADDR_MCAST) { 953 if (dest->addrtype == TIPC_ADDR_MCAST) {
954 rc = tipc_sendmcast(sock, seq, iov, dsz, timeo); 954 rc = tipc_sendmcast(sock, seq, m, dsz, timeo);
955 goto exit; 955 goto exit;
956 } else if (dest->addrtype == TIPC_ADDR_NAME) { 956 } else if (dest->addrtype == TIPC_ADDR_NAME) {
957 u32 type = dest->addr.name.name.type; 957 u32 type = dest->addr.name.name.type;