diff options
author | Sawan Chandak <schandak@marvell.com> | 2019-01-25 08:23:48 +0100 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2019-02-06 03:41:16 +0100 |
commit | dcbf8f8087ebc4d721fd55c4c2072f1a97f6ef6d (patch) | |
tree | fe8ed833880b808db7a1de6c8c5830020d554bcb | |
parent | scsi: qla2xxx: Prevent memory leak for CT req/rsp allocation (diff) | |
download | linux-dcbf8f8087ebc4d721fd55c4c2072f1a97f6ef6d.tar.xz linux-dcbf8f8087ebc4d721fd55c4c2072f1a97f6ef6d.zip |
scsi: qla2xxx: Restore FAWWPN of Physical Port only for loop down
When loop was made down explicitly due to cable pull, then for N2N toplogy,
if FAWWPN BIT is enabled by user, then it would restore some default
(garbage) value for Physical port WWPN, so this show garbage WWPN for the
port. Fix is, to restore physical port WWPN, if it is fabric
configuration. When loop is explicitly made down, and FAWWPN feature is
enabled, then driver need to restore original flashed WWPN.
Signed-off-by: Sawan Chandak <schandak@marvell.com>
Signed-off-by: Himanshu Madhani <hmadhani@marvell.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
-rw-r--r-- | drivers/scsi/qla2xxx/qla_isr.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c index 5c1de6ed825b..bde9940ea7d1 100644 --- a/drivers/scsi/qla2xxx/qla_isr.c +++ b/drivers/scsi/qla2xxx/qla_isr.c @@ -834,7 +834,8 @@ skip_rio: * Restore for Physical Port only */ if (!vha->vp_idx) { - if (ha->flags.fawwpn_enabled) { + if (ha->flags.fawwpn_enabled && + (ha->current_topology == ISP_CFG_F)) { void *wwpn = ha->init_cb->port_name; memcpy(vha->port_name, wwpn, WWN_SIZE); fc_host_port_name(vha->host) = |