Skip to content

Commit 0afb3bc

Browse files
Quinn Trangregkh
authored andcommitted
scsi: qla2xxx: Turn off target reset during issue_lip
[ Upstream commit 0b7a9fd ] When user uses issue_lip to do link bounce, driver sends additional target reset to remote device before resetting the link. The target reset would affect other paths with active I/Os. This patch will remove the unnecessary target reset. Link: https://lore.kernel.org/r/20211026115412.27691-4-njavali@marvell.com Fixes: 5854771 ("[SCSI] qla2xxx: Add ISPFX00 specific bus reset routine") Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com> Signed-off-by: Quinn Tran <qutran@marvell.com> Signed-off-by: Nilesh Javali <njavali@marvell.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent 09595fd commit 0afb3bc

3 files changed

Lines changed: 2 additions & 50 deletions

File tree

‎drivers/scsi/qla2xxx/qla_gbl.h‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,6 @@ extern int ql2xasynctmfenable;
158158
extern int ql2xgffidenable;
159159
extern int ql2xenabledif;
160160
extern int ql2xenablehba_err_chk;
161-
extern int ql2xtargetreset;
162161
extern int ql2xdontresethba;
163162
extern uint64_t ql2xmaxlun;
164163
extern int ql2xmdcapmask;
@@ -791,7 +790,6 @@ extern void qlafx00_abort_iocb(srb_t *, struct abort_iocb_entry_fx00 *);
791790
extern void qlafx00_fxdisc_iocb(srb_t *, struct fxdisc_entry_fx00 *);
792791
extern void qlafx00_timer_routine(scsi_qla_host_t *);
793792
extern int qlafx00_rescan_isp(scsi_qla_host_t *);
794-
extern int qlafx00_loop_reset(scsi_qla_host_t *vha);
795793

796794
/* qla82xx related functions */
797795

‎drivers/scsi/qla2xxx/qla_mr.c‎

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -738,29 +738,6 @@ qlafx00_lun_reset(fc_port_t *fcport, uint64_t l, int tag)
738738
return qla2x00_async_tm_cmd(fcport, TCF_LUN_RESET, l, tag);
739739
}
740740

741-
int
742-
qlafx00_loop_reset(scsi_qla_host_t *vha)
743-
{
744-
int ret;
745-
struct fc_port *fcport;
746-
struct qla_hw_data *ha = vha->hw;
747-
748-
if (ql2xtargetreset) {
749-
list_for_each_entry(fcport, &vha->vp_fcports, list) {
750-
if (fcport->port_type != FCT_TARGET)
751-
continue;
752-
753-
ret = ha->isp_ops->target_reset(fcport, 0, 0);
754-
if (ret != QLA_SUCCESS) {
755-
ql_dbg(ql_dbg_taskm, vha, 0x803d,
756-
"Bus Reset failed: Reset=%d "
757-
"d_id=%x.\n", ret, fcport->d_id.b24);
758-
}
759-
}
760-
}
761-
return QLA_SUCCESS;
762-
}
763-
764741
int
765742
qlafx00_iospace_config(struct qla_hw_data *ha)
766743
{

‎drivers/scsi/qla2xxx/qla_os.c‎

Lines changed: 2 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -197,12 +197,6 @@ MODULE_PARM_DESC(ql2xdbwr,
197197
" 0 -- Regular doorbell.\n"
198198
" 1 -- CAMRAM doorbell (faster).\n");
199199

200-
int ql2xtargetreset = 1;
201-
module_param(ql2xtargetreset, int, S_IRUGO);
202-
MODULE_PARM_DESC(ql2xtargetreset,
203-
"Enable target reset."
204-
"Default is 1 - use hw defaults.");
205-
206200
int ql2xgffidenable;
207201
module_param(ql2xgffidenable, int, S_IRUGO);
208202
MODULE_PARM_DESC(ql2xgffidenable,
@@ -1652,27 +1646,10 @@ int
16521646
qla2x00_loop_reset(scsi_qla_host_t *vha)
16531647
{
16541648
int ret;
1655-
struct fc_port *fcport;
16561649
struct qla_hw_data *ha = vha->hw;
16571650

1658-
if (IS_QLAFX00(ha)) {
1659-
return qlafx00_loop_reset(vha);
1660-
}
1661-
1662-
if (ql2xtargetreset == 1 && ha->flags.enable_target_reset) {
1663-
list_for_each_entry(fcport, &vha->vp_fcports, list) {
1664-
if (fcport->port_type != FCT_TARGET)
1665-
continue;
1666-
1667-
ret = ha->isp_ops->target_reset(fcport, 0, 0);
1668-
if (ret != QLA_SUCCESS) {
1669-
ql_dbg(ql_dbg_taskm, vha, 0x802c,
1670-
"Bus Reset failed: Reset=%d "
1671-
"d_id=%x.\n", ret, fcport->d_id.b24);
1672-
}
1673-
}
1674-
}
1675-
1651+
if (IS_QLAFX00(ha))
1652+
return QLA_SUCCESS;
16761653

16771654
if (ha->flags.enable_lip_full_login && !IS_CNA_CAPABLE(ha)) {
16781655
atomic_set(&vha->loop_state, LOOP_DOWN);

0 commit comments

Comments
 (0)