diff options
author | Yang, Bo <Bo.Yang@lsi.com> | 2009-12-06 10:24:21 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2010-02-17 14:11:26 -0500 |
commit | 780a3762fb9208748baac5aa9c63a4d4c9287753 (patch) | |
tree | 07dc26d9e93d349269d964c0f861751f548fc126 /drivers/scsi/megaraid | |
parent | 7c0616b85ba23d0467bf0b5a6f288f5296eb05ff (diff) |
[SCSI] megaraid_sas: Zero pad_0 in mfi structure
Add the pad_0 in mfi frame structure to 0 to fix the context value
larger than 32bit value issue.
Signed-off-by Bo Yang<bo.yang@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/megaraid')
-rw-r--r-- | drivers/scsi/megaraid/megaraid_sas.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/scsi/megaraid/megaraid_sas.c b/drivers/scsi/megaraid/megaraid_sas.c index 708ea3157b60..18d3a312c29f 100644 --- a/drivers/scsi/megaraid/megaraid_sas.c +++ b/drivers/scsi/megaraid/megaraid_sas.c | |||
@@ -843,6 +843,7 @@ megasas_build_dcdb(struct megasas_instance *instance, struct scsi_cmnd *scp, | |||
843 | pthru->lun = scp->device->lun; | 843 | pthru->lun = scp->device->lun; |
844 | pthru->cdb_len = scp->cmd_len; | 844 | pthru->cdb_len = scp->cmd_len; |
845 | pthru->timeout = 0; | 845 | pthru->timeout = 0; |
846 | pthru->pad_0 = 0; | ||
846 | pthru->flags = flags; | 847 | pthru->flags = flags; |
847 | pthru->data_xfer_len = scsi_bufflen(scp); | 848 | pthru->data_xfer_len = scsi_bufflen(scp); |
848 | 849 | ||
@@ -2250,6 +2251,7 @@ megasas_get_pd_list(struct megasas_instance *instance) | |||
2250 | dcmd->sge_count = 1; | 2251 | dcmd->sge_count = 1; |
2251 | dcmd->flags = MFI_FRAME_DIR_READ; | 2252 | dcmd->flags = MFI_FRAME_DIR_READ; |
2252 | dcmd->timeout = 0; | 2253 | dcmd->timeout = 0; |
2254 | dcmd->pad_0 = 0; | ||
2253 | dcmd->data_xfer_len = MEGASAS_MAX_PD * sizeof(struct MR_PD_LIST); | 2255 | dcmd->data_xfer_len = MEGASAS_MAX_PD * sizeof(struct MR_PD_LIST); |
2254 | dcmd->opcode = MR_DCMD_PD_LIST_QUERY; | 2256 | dcmd->opcode = MR_DCMD_PD_LIST_QUERY; |
2255 | dcmd->sgl.sge32[0].phys_addr = ci_h; | 2257 | dcmd->sgl.sge32[0].phys_addr = ci_h; |
@@ -2339,6 +2341,7 @@ megasas_get_ctrl_info(struct megasas_instance *instance, | |||
2339 | dcmd->sge_count = 1; | 2341 | dcmd->sge_count = 1; |
2340 | dcmd->flags = MFI_FRAME_DIR_READ; | 2342 | dcmd->flags = MFI_FRAME_DIR_READ; |
2341 | dcmd->timeout = 0; | 2343 | dcmd->timeout = 0; |
2344 | dcmd->pad_0 = 0; | ||
2342 | dcmd->data_xfer_len = sizeof(struct megasas_ctrl_info); | 2345 | dcmd->data_xfer_len = sizeof(struct megasas_ctrl_info); |
2343 | dcmd->opcode = MR_DCMD_CTRL_GET_INFO; | 2346 | dcmd->opcode = MR_DCMD_CTRL_GET_INFO; |
2344 | dcmd->sgl.sge32[0].phys_addr = ci_h; | 2347 | dcmd->sgl.sge32[0].phys_addr = ci_h; |
@@ -2714,6 +2717,7 @@ megasas_get_seq_num(struct megasas_instance *instance, | |||
2714 | dcmd->sge_count = 1; | 2717 | dcmd->sge_count = 1; |
2715 | dcmd->flags = MFI_FRAME_DIR_READ; | 2718 | dcmd->flags = MFI_FRAME_DIR_READ; |
2716 | dcmd->timeout = 0; | 2719 | dcmd->timeout = 0; |
2720 | dcmd->pad_0 = 0; | ||
2717 | dcmd->data_xfer_len = sizeof(struct megasas_evt_log_info); | 2721 | dcmd->data_xfer_len = sizeof(struct megasas_evt_log_info); |
2718 | dcmd->opcode = MR_DCMD_CTRL_EVENT_GET_INFO; | 2722 | dcmd->opcode = MR_DCMD_CTRL_EVENT_GET_INFO; |
2719 | dcmd->sgl.sge32[0].phys_addr = el_info_h; | 2723 | dcmd->sgl.sge32[0].phys_addr = el_info_h; |
@@ -2828,6 +2832,7 @@ megasas_register_aen(struct megasas_instance *instance, u32 seq_num, | |||
2828 | dcmd->sge_count = 1; | 2832 | dcmd->sge_count = 1; |
2829 | dcmd->flags = MFI_FRAME_DIR_READ; | 2833 | dcmd->flags = MFI_FRAME_DIR_READ; |
2830 | dcmd->timeout = 0; | 2834 | dcmd->timeout = 0; |
2835 | dcmd->pad_0 = 0; | ||
2831 | dcmd->data_xfer_len = sizeof(struct megasas_evt_detail); | 2836 | dcmd->data_xfer_len = sizeof(struct megasas_evt_detail); |
2832 | dcmd->opcode = MR_DCMD_CTRL_EVENT_WAIT; | 2837 | dcmd->opcode = MR_DCMD_CTRL_EVENT_WAIT; |
2833 | dcmd->mbox.w[0] = seq_num; | 2838 | dcmd->mbox.w[0] = seq_num; |
@@ -3166,6 +3171,7 @@ static void megasas_flush_cache(struct megasas_instance *instance) | |||
3166 | dcmd->sge_count = 0; | 3171 | dcmd->sge_count = 0; |
3167 | dcmd->flags = MFI_FRAME_DIR_NONE; | 3172 | dcmd->flags = MFI_FRAME_DIR_NONE; |
3168 | dcmd->timeout = 0; | 3173 | dcmd->timeout = 0; |
3174 | dcmd->pad_0 = 0; | ||
3169 | dcmd->data_xfer_len = 0; | 3175 | dcmd->data_xfer_len = 0; |
3170 | dcmd->opcode = MR_DCMD_CTRL_CACHE_FLUSH; | 3176 | dcmd->opcode = MR_DCMD_CTRL_CACHE_FLUSH; |
3171 | dcmd->mbox.b[0] = MR_FLUSH_CTRL_CACHE | MR_FLUSH_DISK_CACHE; | 3177 | dcmd->mbox.b[0] = MR_FLUSH_CTRL_CACHE | MR_FLUSH_DISK_CACHE; |
@@ -3205,6 +3211,7 @@ static void megasas_shutdown_controller(struct megasas_instance *instance, | |||
3205 | dcmd->sge_count = 0; | 3211 | dcmd->sge_count = 0; |
3206 | dcmd->flags = MFI_FRAME_DIR_NONE; | 3212 | dcmd->flags = MFI_FRAME_DIR_NONE; |
3207 | dcmd->timeout = 0; | 3213 | dcmd->timeout = 0; |
3214 | dcmd->pad_0 = 0; | ||
3208 | dcmd->data_xfer_len = 0; | 3215 | dcmd->data_xfer_len = 0; |
3209 | dcmd->opcode = opcode; | 3216 | dcmd->opcode = opcode; |
3210 | 3217 | ||