scsi: lpfc: FCoE VPort enable-disable does not bring up the VPort
[ Upstream commit 104450eb08
]
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>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
01347f537f
commit
b4e42f5d01
@ -537,6 +537,12 @@ enable_vport(struct fc_vport *fc_vport)
|
|||||||
|
|
||||||
spin_lock_irq(shost->host_lock);
|
spin_lock_irq(shost->host_lock);
|
||||||
vport->load_flag |= FC_LOADING;
|
vport->load_flag |= FC_LOADING;
|
||||||
|
if (vport->fc_flag & FC_VPORT_NEEDS_INIT_VPI) {
|
||||||
|
spin_unlock_irq(shost->host_lock);
|
||||||
|
lpfc_issue_init_vpi(vport);
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
|
||||||
vport->fc_flag |= FC_VPORT_NEEDS_REG_VPI;
|
vport->fc_flag |= FC_VPORT_NEEDS_REG_VPI;
|
||||||
spin_unlock_irq(shost->host_lock);
|
spin_unlock_irq(shost->host_lock);
|
||||||
|
|
||||||
@ -557,6 +563,8 @@ enable_vport(struct fc_vport *fc_vport)
|
|||||||
} else {
|
} else {
|
||||||
lpfc_vport_set_state(vport, FC_VPORT_FAILED);
|
lpfc_vport_set_state(vport, FC_VPORT_FAILED);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
out:
|
||||||
lpfc_printf_vlog(vport, KERN_ERR, LOG_VPORT,
|
lpfc_printf_vlog(vport, KERN_ERR, LOG_VPORT,
|
||||||
"1827 Vport Enabled.\n");
|
"1827 Vport Enabled.\n");
|
||||||
return VPORT_OK;
|
return VPORT_OK;
|
||||||
|
Reference in New Issue
Block a user