@@ -857,10 +857,9 @@ lpfc_port_link_failure(struct lpfc_vport *vport)
857857void
858858lpfc_linkdown_port (struct lpfc_vport * vport )
859859{
860- struct lpfc_hba * phba = vport -> phba ;
861860 struct Scsi_Host * shost = lpfc_shost_from_vport (vport );
862861
863- if (phba -> cfg_enable_fc4_type != LPFC_ENABLE_NVME )
862+ if (vport -> cfg_enable_fc4_type != LPFC_ENABLE_NVME )
864863 fc_host_post_event (shost , fc_get_event_number (),
865864 FCH_EVT_LINKDOWN , 0 );
866865
@@ -923,8 +922,8 @@ lpfc_linkdown(struct lpfc_hba *phba)
923922
924923 vports [i ]-> fc_myDID = 0 ;
925924
926- if ((phba -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
927- (phba -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )) {
925+ if ((vport -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
926+ (vport -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )) {
928927 if (phba -> nvmet_support )
929928 lpfc_nvmet_update_targetport (phba );
930929 else
@@ -1010,7 +1009,7 @@ lpfc_linkup_port(struct lpfc_vport *vport)
10101009 (vport != phba -> pport ))
10111010 return ;
10121011
1013- if (phba -> cfg_enable_fc4_type != LPFC_ENABLE_NVME )
1012+ if (vport -> cfg_enable_fc4_type != LPFC_ENABLE_NVME )
10141013 fc_host_post_event (shost , fc_get_event_number (),
10151014 FCH_EVT_LINKUP , 0 );
10161015
@@ -3658,8 +3657,8 @@ lpfc_mbx_cmpl_reg_vpi(struct lpfc_hba *phba, LPFC_MBOXQ_t *pmb)
36583657 spin_unlock_irq (shost -> host_lock );
36593658 vport -> fc_myDID = 0 ;
36603659
3661- if ((phba -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
3662- (phba -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )) {
3660+ if ((vport -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
3661+ (vport -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )) {
36633662 if (phba -> nvmet_support )
36643663 lpfc_nvmet_update_targetport (phba );
36653664 else
@@ -3921,11 +3920,9 @@ lpfc_mbx_cmpl_fabric_reg_login(struct lpfc_hba *phba, LPFC_MBOXQ_t *pmb)
39213920int
39223921lpfc_issue_gidft (struct lpfc_vport * vport )
39233922{
3924- struct lpfc_hba * phba = vport -> phba ;
3925-
39263923 /* Good status, issue CT Request to NameServer */
3927- if ((phba -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
3928- (phba -> cfg_enable_fc4_type == LPFC_ENABLE_FCP )) {
3924+ if ((vport -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
3925+ (vport -> cfg_enable_fc4_type == LPFC_ENABLE_FCP )) {
39293926 if (lpfc_ns_cmd (vport , SLI_CTNS_GID_FT , 0 , SLI_CTPT_FCP )) {
39303927 /* Cannot issue NameServer FCP Query, so finish up
39313928 * discovery
@@ -3940,8 +3937,8 @@ lpfc_issue_gidft(struct lpfc_vport *vport)
39403937 vport -> gidft_inp ++ ;
39413938 }
39423939
3943- if ((phba -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
3944- (phba -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )) {
3940+ if ((vport -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
3941+ (vport -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )) {
39453942 if (lpfc_ns_cmd (vport , SLI_CTNS_GID_FT , 0 , SLI_CTPT_NVME )) {
39463943 /* Cannot issue NameServer NVME Query, so finish up
39473944 * discovery
@@ -4057,12 +4054,12 @@ lpfc_mbx_cmpl_ns_reg_login(struct lpfc_hba *phba, LPFC_MBOXQ_t *pmb)
40574054 lpfc_ns_cmd (vport , SLI_CTNS_RSPN_ID , 0 , 0 );
40584055 lpfc_ns_cmd (vport , SLI_CTNS_RFT_ID , 0 , 0 );
40594056
4060- if ((phba -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
4061- (phba -> cfg_enable_fc4_type == LPFC_ENABLE_FCP ))
4057+ if ((vport -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
4058+ (vport -> cfg_enable_fc4_type == LPFC_ENABLE_FCP ))
40624059 lpfc_ns_cmd (vport , SLI_CTNS_RFF_ID , 0 , FC_TYPE_FCP );
40634060
4064- if ((phba -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
4065- (phba -> cfg_enable_fc4_type == LPFC_ENABLE_NVME ))
4061+ if ((vport -> cfg_enable_fc4_type == LPFC_ENABLE_BOTH ) ||
4062+ (vport -> cfg_enable_fc4_type == LPFC_ENABLE_NVME ))
40664063 lpfc_ns_cmd (vport , SLI_CTNS_RFF_ID , 0 ,
40674064 FC_TYPE_NVME );
40684065
@@ -4098,7 +4095,7 @@ lpfc_register_remote_port(struct lpfc_vport *vport, struct lpfc_nodelist *ndlp)
40984095 struct fc_rport_identifiers rport_ids ;
40994096 struct lpfc_hba * phba = vport -> phba ;
41004097
4101- if (phba -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )
4098+ if (vport -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )
41024099 return ;
41034100
41044101 /* Remote port has reappeared. Re-register w/ FC transport */
@@ -4173,9 +4170,8 @@ lpfc_unregister_remote_port(struct lpfc_nodelist *ndlp)
41734170{
41744171 struct fc_rport * rport = ndlp -> rport ;
41754172 struct lpfc_vport * vport = ndlp -> vport ;
4176- struct lpfc_hba * phba = vport -> phba ;
41774173
4178- if (phba -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )
4174+ if (vport -> cfg_enable_fc4_type == LPFC_ENABLE_NVME )
41794175 return ;
41804176
41814177 lpfc_debugfs_disc_trc (vport , LPFC_DISC_TRC_RPORT ,
0 commit comments