diff options
author | adam radford <aradford@gmail.com> | 2012-10-01 22:27:12 -0400 |
---|---|---|
committer | James Bottomley <JBottomley@Parallels.com> | 2012-10-09 06:19:11 -0400 |
commit | e187df63991b1b50af0fd3cf8ceaf9aa77c20f4a (patch) | |
tree | aa1ec67702069b462fe584acc361064480479b08 /drivers/scsi/megaraid | |
parent | f9eff81584ce8727ac6d4dc418f546337781943b (diff) |
[SCSI] megaraid_sas: Add array boundary check for SystemPD
Signed-off-by: Adam Radford <aradford@gmail.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/megaraid')
-rw-r--r-- | drivers/scsi/megaraid/megaraid_sas_fusion.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/megaraid/megaraid_sas_fusion.c b/drivers/scsi/megaraid/megaraid_sas_fusion.c index 31d397497c45..ad6e2ac196b0 100644 --- a/drivers/scsi/megaraid/megaraid_sas_fusion.c +++ b/drivers/scsi/megaraid/megaraid_sas_fusion.c | |||
@@ -1508,7 +1508,8 @@ megasas_build_dcdb_fusion(struct megasas_instance *instance, | |||
1508 | local_map_ptr = fusion->ld_map[(instance->map_id & 1)]; | 1508 | local_map_ptr = fusion->ld_map[(instance->map_id & 1)]; |
1509 | 1509 | ||
1510 | /* Check if this is a system PD I/O */ | 1510 | /* Check if this is a system PD I/O */ |
1511 | if (instance->pd_list[pd_index].driveState == MR_PD_STATE_SYSTEM) { | 1511 | if (scmd->device->channel < MEGASAS_MAX_PD_CHANNELS && |
1512 | instance->pd_list[pd_index].driveState == MR_PD_STATE_SYSTEM) { | ||
1512 | io_request->Function = 0; | 1513 | io_request->Function = 0; |
1513 | io_request->DevHandle = | 1514 | io_request->DevHandle = |
1514 | local_map_ptr->raidMap.devHndlInfo[device_id].curDevHdl; | 1515 | local_map_ptr->raidMap.devHndlInfo[device_id].curDevHdl; |