]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: lpfc: Rework FDMI initialization after link up
authorJames Smart <jsmart2021@gmail.com>
Fri, 6 May 2022 03:55:16 +0000 (20:55 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 11 May 2022 02:12:04 +0000 (22:12 -0400)
commit1e6fa1f2e0c051a925c261b45728987dd85a19e5
treeec9648e157e73392670f24f0164f30f4645fdd70
parent48ee5f40339d5ef84d54fca4495d4b67d0fd58d2
scsi: lpfc: Rework FDMI initialization after link up

After a link up, it's possible for the switch to change FDMI support (e.g.
FDMI1 vs FDMI2 vs SmartSAN).  If the switch reverts to FDMI1, then the
revert is currently not detected.

Additionally, when NPIV is configured, it's possible the physical port's
RHBA is unprocessed by the switch before reciept of an NPIV port issued
RPRT.  This causes some switches vendors to reject the NPIV's RPRT.

Fix by reinitializing base FDMI mode on link up, and defer FDMI vport RPRT
submission until after confirming physical port's RHBA is completed.

Link: https://lore.kernel.org/r/20220506035519.50908-10-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.h
drivers/scsi/lpfc/lpfc_crtn.h
drivers/scsi/lpfc/lpfc_ct.c
drivers/scsi/lpfc/lpfc_hbadisc.c
drivers/scsi/lpfc/lpfc_init.c