Commit e187df63 authored by adam radford's avatar adam radford Committed by James Bottomley

[SCSI] megaraid_sas: Add array boundary check for SystemPD

Signed-off-by: default avatarAdam Radford <aradford@gmail.com>
Signed-off-by: default avatarJames Bottomley <JBottomley@Parallels.com>
parent f9eff815
...@@ -1508,7 +1508,8 @@ megasas_build_dcdb_fusion(struct megasas_instance *instance, ...@@ -1508,7 +1508,8 @@ megasas_build_dcdb_fusion(struct megasas_instance *instance,
local_map_ptr = fusion->ld_map[(instance->map_id & 1)]; local_map_ptr = fusion->ld_map[(instance->map_id & 1)];
/* Check if this is a system PD I/O */ /* Check if this is a system PD I/O */
if (instance->pd_list[pd_index].driveState == MR_PD_STATE_SYSTEM) { if (scmd->device->channel < MEGASAS_MAX_PD_CHANNELS &&
instance->pd_list[pd_index].driveState == MR_PD_STATE_SYSTEM) {
io_request->Function = 0; io_request->Function = 0;
io_request->DevHandle = io_request->DevHandle =
local_map_ptr->raidMap.devHndlInfo[device_id].curDevHdl; local_map_ptr->raidMap.devHndlInfo[device_id].curDevHdl;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment