Skip to content

Commit c191751

Browse files
keithbuschkuba-moo
authored andcommitted
caif: don't assume iov_iter type
The details of the iov_iter types are appropriately abstracted, so there's no need to check for specific type fields. Just let the abstractions handle it. This is preparing for io_uring/net's io_send to utilize the more efficient ITER_UBUF. Signed-off-by: Keith Busch <kbusch@kernel.org> Reviewed-by: Jens Axboe <axboe@kernel.dk> Link: https://lore.kernel.org/r/20230111184245.3784393-1-kbusch@meta.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent e471d83 commit c191751

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

net/caif/caif_socket.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -533,10 +533,6 @@ static int caif_seqpkt_sendmsg(struct socket *sock, struct msghdr *msg,
533533
if (msg->msg_namelen)
534534
goto err;
535535

536-
ret = -EINVAL;
537-
if (unlikely(msg->msg_iter.nr_segs == 0) ||
538-
unlikely(msg->msg_iter.iov->iov_base == NULL))
539-
goto err;
540536
noblock = msg->msg_flags & MSG_DONTWAIT;
541537

542538
timeo = sock_sndtimeo(sk, noblock);

0 commit comments

Comments
 (0)