Re: [PATCH v4] nvme-tcp: fix connect failure on receiving partial ICResp PDU
From: Maurizio Lombardi
Date: Mon Jan 27 2025 - 12:51:42 EST
po 27. 1. 2025 v 18:39 odesílatel Caleb Sander <csander@xxxxxxxxxxxxxxx> napsal:
> > > + msg.msg_flags = MSG_WAITALL;
> > > ret = kernel_recvmsg(queue->sock, &msg, &iov, 1,
> > > iov.iov_len, msg.msg_flags);
> >
> > But won't we have to wait for a TCP timeout now if the sender sends less
> > than 128 bytes? With this patch we always wait for 128 bytes, and
> > possibly wait for TCP timeout if not.
>
> Yes, if the NVMe/TCP controller sends less than 128 bytes, we need to
> wait for it to send the remainder of the ICResp PDU.
I guess what Hannes wanted to ask is whether it makes sense to
check if ret is a number greater than 0 but less than 128,
given that the MSG_WAITALL flag has been set.
Maurizio