Skip to content

Commit a7e7d31

Browse files
James Smartgregkh
authored andcommitted
scsi: lpfc: FCoE VPort enable-disable does not bring up the VPort
[ Upstream commit 104450eb08ca662e6b1d02da11aca9598e978f3e ] FCoE VPort enable-disable does not bring up the VPort. VPI structure needed to be initialized before being re-registered. 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> Signed-off-by: Sasha Levin <alexander.levin@verizon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 18477ba commit a7e7d31

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

drivers/scsi/lpfc/lpfc_vport.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -528,6 +528,12 @@ enable_vport(struct fc_vport *fc_vport)
528528

529529
spin_lock_irq(shost->host_lock);
530530
vport->load_flag |= FC_LOADING;
531+
if (vport->fc_flag & FC_VPORT_NEEDS_INIT_VPI) {
532+
spin_unlock_irq(shost->host_lock);
533+
lpfc_issue_init_vpi(vport);
534+
goto out;
535+
}
536+
531537
vport->fc_flag |= FC_VPORT_NEEDS_REG_VPI;
532538
spin_unlock_irq(shost->host_lock);
533539

@@ -548,6 +554,8 @@ enable_vport(struct fc_vport *fc_vport)
548554
} else {
549555
lpfc_vport_set_state(vport, FC_VPORT_FAILED);
550556
}
557+
558+
out:
551559
lpfc_printf_vlog(vport, KERN_ERR, LOG_VPORT,
552560
"1827 Vport Enabled.\n");
553561
return VPORT_OK;

0 commit comments

Comments
 (0)