OSDN Git Service

scsi: lpfc: Don't remove ndlp on PRLI errors in P2P mode
authorJames Smart <jsmart2021@gmail.com>
Fri, 10 Sep 2021 23:31:51 +0000 (16:31 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 15 Sep 2021 03:33:21 +0000 (23:33 -0400)
commita864ee709bc06095463c61fc22a4dc899fba1758
treebe6cf6a38a6639d75a3ec720ba363c6405f52d59
parent3a874488d2e936340e165070a41508208d816fc3
scsi: lpfc: Don't remove ndlp on PRLI errors in P2P mode

In pt-2-pt mode, the initiator does not log into the target after a PRLI
error.  In pt-2-pt mode, the target responded to the PRLI by sending a
LOGO. The LOGO causes all ELS and I/Os to be aborted. This caused the PRLI
to fail. The PRLI completion path caused the discovery node to be dropped
to avoid being stick in an UNUSED (not logged in) state. As the node was
dropped there is no retry of the login and as it is pt-2-pt, there is no
RSCN to retrigger discovery. Thus the other end is not seen by the OS.

Fix by ensuring the discovery node is not dropped if connecting pt-2-pt.
This will cause PLOGI to be retried.

Link: https://lore.kernel.org/r/20210910233159.115896-7-jsmart2021@gmail.com
Co-developed-by: Justin Tee <justin.tee@broadcom.com>
Signed-off-by: Justin Tee <justin.tee@broadcom.com>
Signed-off-by: James Smart <jsmart2021@gmail.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/lpfc/lpfc_els.c