diff options
author | Kashyap, Desai <kashyap.desai@lsi.com> | 2010-02-17 11:38:36 +0100 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2010-02-18 00:49:25 +0100 |
commit | 3ed215259f2d8cd937abc833dc76e309173aaa52 (patch) | |
tree | 9728404b0eb064096c7053efca1014bd6d350291 /drivers/scsi | |
parent | [SCSI] zfcp: Introduce header file for qdio structs and inline functions (diff) | |
download | linux-3ed215259f2d8cd937abc833dc76e309173aaa52.tar.xz linux-3ed215259f2d8cd937abc833dc76e309173aaa52.zip |
[SCSI] mpt2sas: Do not call sas_is_tlr_enabled for RAID volumes.
For RAID volume sas_is_tlr_enabled call will hit BUG at
scsi_transport_sas.c:163, since raid volume
is not visible to sas transport layer.
Now Added check to make sure arg pass in sas_is_tlr_enabled() is not a volume.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/mpt2sas/mpt2sas_scsih.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/scsi/mpt2sas/mpt2sas_scsih.c b/drivers/scsi/mpt2sas/mpt2sas_scsih.c index 344a22ad2f33..c7ec3f174782 100644 --- a/drivers/scsi/mpt2sas/mpt2sas_scsih.c +++ b/drivers/scsi/mpt2sas/mpt2sas_scsih.c @@ -3062,8 +3062,9 @@ _scsih_qcmd(struct scsi_cmnd *scmd, void (*done)(struct scsi_cmnd *)) } else mpi_control |= MPI2_SCSIIO_CONTROL_SIMPLEQ; - - if (sas_is_tlr_enabled(scmd->device)) + /* Make sure Device is not raid volume */ + if (!_scsih_is_raid(&scmd->device->sdev_gendev) && + sas_is_tlr_enabled(scmd->device)) mpi_control |= MPI2_SCSIIO_CONTROL_TLR_ON; smid = mpt2sas_base_get_smid_scsiio(ioc, ioc->scsi_io_cb_idx, scmd); @@ -3452,7 +3453,8 @@ _scsih_io_done(struct MPT2SAS_ADAPTER *ioc, u16 smid, u8 msix_index, u32 reply) le32_to_cpu(mpi_reply->ResponseInfo) & 0xFF; if (!sas_device_priv_data->tlr_snoop_check) { sas_device_priv_data->tlr_snoop_check++; - if (sas_is_tlr_enabled(scmd->device) && + if (!_scsih_is_raid(&scmd->device->sdev_gendev) && + sas_is_tlr_enabled(scmd->device) && response_code == MPI2_SCSITASKMGMT_RSP_INVALID_FRAME) { sas_disable_tlr(scmd->device); sdev_printk(KERN_INFO, scmd->device, "TLR disabled\n"); |