]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
cxgbe tom: Permit rcv_nxt mismatches on FIN for iSCSI connections on T6.
authorJohn Baldwin <jhb@FreeBSD.org>
Mon, 2 Aug 2021 16:41:27 +0000 (09:41 -0700)
committerJohn Baldwin <jhb@FreeBSD.org>
Mon, 2 Aug 2021 16:41:27 +0000 (09:41 -0700)
commitd59f1c49e26ba29e7583019bb5d6aa029466fdb6
treef4a13f1450238db12123ca61c566be6c9aa5e599
parent600745f1e2260e7ed3c2e6183b24388ff38c916c
cxgbe tom: Permit rcv_nxt mismatches on FIN for iSCSI connections on T6.

The remote peer might send a FIN in the middle of a burst of data
PDUs.  In the case of T6 with data PDU completion moderation, the
driver would not have seen these PDUs since the final PDU in the burst
was never received resulting in a stale rcv_nxt when the FIN is
received.

While here, invert the logic in the condition to be more readable and
always set tp->rcv_nxt from the sequence number in the CPL.  This sets
the proper value of rcv_nxt for FINs on connections with data received
but not reported via a CPL (e.g. a partial iSCSI PDU burst interrupted
by a FIN).

Reported by: Jithesh Arakkan @ Chelsio
Reviewed by: np
Sponsored by: Chelsio Communications
Differential Revision: https://reviews.freebsd.org/D30871
sys/dev/cxgbe/tom/t4_cpl_io.c