linux-next: manual merge of the block tree with Linus' tree

From: Stephen Rothwell
Date: Sun Jun 25 2023 - 23:04:25 EST


Hi all,

Today's linux-next merge of the block tree got a conflict in:

io_uring/net.c

between commit:

78d0d2063bab ("io_uring/net: disable partial retries for recvmsg with cmsg")

from Linus' tree and commit:

88fc8b8463b0 ("io_uring/net: initalize msghdr->msg_inq to known value")

from the block tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging. You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

--
Cheers,
Stephen Rothwell

diff --cc io_uring/net.c
index 4b8e84768d2a,369167e45fa8..000000000000
--- a/io_uring/net.c
+++ b/io_uring/net.c
@@@ -790,19 -794,17 +803,20 @@@ retry_multishot
flags = sr->msg_flags;
if (force_nonblock)
flags |= MSG_DONTWAIT;
- if (flags & MSG_WAITALL)
- min_ret = iov_iter_count(&kmsg->msg.msg_iter);

kmsg->msg.msg_get_inq = 1;
+ kmsg->msg.msg_inq = -1U;
- if (req->flags & REQ_F_APOLL_MULTISHOT)
+ if (req->flags & REQ_F_APOLL_MULTISHOT) {
ret = io_recvmsg_multishot(sock, sr, kmsg, flags,
&mshot_finished);
- else
+ } else {
+ /* disable partial retry for recvmsg with cmsg attached */
+ if (flags & MSG_WAITALL && !kmsg->msg.msg_controllen)
+ min_ret = iov_iter_count(&kmsg->msg.msg_iter);
+
ret = __sys_recvmsg_sock(sock, &kmsg->msg, sr->umsg,
kmsg->uaddr, flags);
+ }

if (ret < min_ret) {
if (ret == -EAGAIN && force_nonblock) {

Attachment: pgpWKlVzZ6Pka.pgp
Description: OpenPGP digital signature