diff options
author | Andy Yan <ayan@marvell.com> | 2009-05-11 09:49:52 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2009-05-23 16:44:08 -0400 |
commit | 0f980a871678b7ec143fcb45b31bf9234e4585c8 (patch) | |
tree | 6178d37572dda96a16d3a21e4d5a21f79f01b7e6 /drivers/scsi/mvsas | |
parent | 0b84b7094e87769120def1e703b8b4d037281038 (diff) |
[SCSI] mvsas: bug fix, null pointer may be used
Null pointer check to avoid corruption.
Signed-off-by: Ying Chu <jasonchu@marvell.com>
Signed-off-by: Andy Yan <ayan@marvell.com>
Signed-off-by: Ke Wei <kewei@marvell.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/mvsas')
-rw-r--r-- | drivers/scsi/mvsas/mv_sas.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/scsi/mvsas/mv_sas.c b/drivers/scsi/mvsas/mv_sas.c index 4279b5e8808a..3fc396fc050d 100644 --- a/drivers/scsi/mvsas/mv_sas.c +++ b/drivers/scsi/mvsas/mv_sas.c | |||
@@ -1873,11 +1873,11 @@ int mvs_slot_complete(struct mvs_info *mvi, u32 rx_desc, u32 flags) | |||
1873 | } | 1873 | } |
1874 | 1874 | ||
1875 | out: | 1875 | out: |
1876 | if (mvi_dev) | 1876 | if (mvi_dev) { |
1877 | mvi_dev->runing_req--; | 1877 | mvi_dev->runing_req--; |
1878 | if (sas_protocol_ata(task->task_proto)) | 1878 | if (sas_protocol_ata(task->task_proto)) |
1879 | mvs_free_reg_set(mvi, mvi_dev); | 1879 | mvs_free_reg_set(mvi, mvi_dev); |
1880 | 1880 | } | |
1881 | mvs_slot_task_free(mvi, task, slot, slot_idx); | 1881 | mvs_slot_task_free(mvi, task, slot, slot_idx); |
1882 | sts = tstat->stat; | 1882 | sts = tstat->stat; |
1883 | 1883 | ||