Re: [PATCH v4] nvme-tcp: fix connect failure on receiving partial ICResp PDU

From: Keith Busch
Date: Tue Feb 18 2025 - 10:45:45 EST


On Fri, Jan 24, 2025 at 11:43:10AM -0700, Caleb Sander Mateos wrote:
> nvme_tcp_init_connection() attempts to receive an ICResp PDU but only
> checks that the return value from recvmsg() is non-negative. If the
> sender closes the TCP connection or sends fewer than 128 bytes, this
> check will pass even though the full PDU wasn't received.
>
> Ensure the full ICResp PDU is received by checking that recvmsg()
> returns the expected 128 bytes.

Thanks, applied to nvme-6.14.