]> asedeno.scripts.mit.edu Git - linux.git/commit
scsi: lpfc: Fix nvme target mode ABTSing a received ABTS
authorJames Smart <jsmart2021@gmail.com>
Wed, 14 Aug 2019 23:56:56 +0000 (16:56 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 20 Aug 2019 02:41:10 +0000 (22:41 -0400)
commit005d8eb92847e6823d9fea6041f7c6f26b6cf2da
treeb794e94af68f0e7a6b28180d6e178db834b3c968
parent84f2ddf8cf317afcfd92e06ed5a25aea48dc200e
scsi: lpfc: Fix nvme target mode ABTSing a received ABTS

If an unsolicited ABTS was received, the driver looks up the exchange it
references. It it does various searches looking for the exchange
context. When one is eventually matched and it is associated with an XRI
context, the driver sends an ABORT WQE to terminate the exchange. Current
code looks at whether the transport had taken action on the XRI yet or not
(no action if set to LPFC_NVMET_STE_RCV; action if non-LPFC_NVMET_STE_RCV).
Based on action or not one of two (sol vs unsol) issue abort routines are
called. The unsol version cheats and transmits a sequence containing an
ABTS with no interaction with the adapter.  The sol version issues an Abort
WQE and lets the adapter manage whether the ABTS is sent to not.

The issue is the unsol version is sending ABTS unconditionally for the
exchange that received the ABTS. It's unnecessary.

Remove the conditional and just call the adapter command-based routine to
let the adapter manage the ABTS.

Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com>
Signed-off-by: James Smart <jsmart2021@gmail.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/lpfc/lpfc_nvmet.c