Skip to content

Commit 8f58fc6

Browse files
abattersbymartinkpetersen
authored andcommitted
scsi: qla2xxx: Fix initiator mode with qlini_mode=exclusive
When given the module parameter qlini_mode=exclusive, qla2xxx in initiator mode is initially unable to successfully send SCSI commands to devices it finds while scanning, resulting in an escalating series of resets until an adapter reset clears the issue. Fix by checking the active mode instead of the module parameter. Signed-off-by: Tony Battersby <tonyb@cybernetics.com> Link: https://patch.msgid.link/1715ec14-ba9a-45dc-9cf2-d41aa6b81b5e@cybernetics.com Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
1 parent b57fbc8 commit 8f58fc6

1 file changed

Lines changed: 1 addition & 7 deletions

File tree

drivers/scsi/qla2xxx/qla_os.c

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3438,13 +3438,7 @@ qla2x00_probe_one(struct pci_dev *pdev, const struct pci_device_id *id)
34383438
ha->mqenable = 0;
34393439

34403440
if (ha->mqenable) {
3441-
bool startit = false;
3442-
3443-
if (QLA_TGT_MODE_ENABLED())
3444-
startit = false;
3445-
3446-
if (ql2x_ini_mode == QLA2XXX_INI_MODE_ENABLED)
3447-
startit = true;
3441+
bool startit = !!(host->active_mode & MODE_INITIATOR);
34483442

34493443
/* Create start of day qpairs for Block MQ */
34503444
for (i = 0; i < ha->max_qpairs; i++)

0 commit comments

Comments
 (0)