]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: lpfc: Fix NVMEI's handling of NVMET's PRLI response attributes
authorJames Smart <jsmart2021@gmail.com>
Mon, 15 May 2017 22:20:50 +0000 (15:20 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 17 May 2017 01:24:17 +0000 (21:24 -0400)
commit0014156ecbbeafba709cadb41df0fb9c53a03ae4
treebc8f847a0677cf5b19df3d1f9806c6b1165e88c7
parent189ce1a1ea576cf2dd821bae0661717b2d75d93a
scsi: lpfc: Fix NVMEI's handling of NVMET's PRLI response attributes

Code review of NVMEI's FC_PORT_ROLE_NVME_DISCOVERY looked wrong.

Discussions with storage architecture team clarified NVMEI's audit of
the PRLI response port roles.  Following up discussion with code review
showed a few minor corrections were required - especially in
anticipation of NVME auto discovery.

During PRLI, NVMEI should sent prli_init - which it it does.  NVMET
should send prli_tgt and prli_disc - which it does.  When NVMEI receives
a PRLI Response now, it audits the incoming target bits and stores the
attributes in the corresponding NDLP.  Later, when NVMEI registers the
NVME rport, it uses the stored ndlp attributes to set the rport
port_roles correctly.

Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com>
Signed-off-by: James Smart <james.smart@broadcom.com>
Reviewed-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/lpfc/lpfc_disc.h
drivers/scsi/lpfc/lpfc_nportdisc.c