diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2012-06-27 11:08:25 +0200 |
---|---|---|
committer | James Bottomley <JBottomley@Parallels.com> | 2012-07-20 09:58:38 +0200 |
commit | 9d5d93e32a365f962fb26ebd19c0b4a392f38e64 (patch) | |
tree | 80a96c1eb47ef1df23c6040a38fb39bc8716dfdb /drivers/scsi | |
parent | [SCSI] bfa: dereferencing freed memory in bfad_im_probe() (diff) | |
download | linux-9d5d93e32a365f962fb26ebd19c0b4a392f38e64.tar.xz linux-9d5d93e32a365f962fb26ebd19c0b4a392f38e64.zip |
[SCSI] megaraid: cleanup type issue in mega_build_cmd()
On 64 bit systems the current code sets 32 bits of "seg" and leaves the
other 32 uninitialized. It doesn't matter since the variable is never
used. But it's still messy and we should fix it.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Adam Radford <aradford@gmail.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/megaraid.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/scsi/megaraid.c b/drivers/scsi/megaraid.c index 4d39a9ffc081..97825f116954 100644 --- a/drivers/scsi/megaraid.c +++ b/drivers/scsi/megaraid.c @@ -524,7 +524,7 @@ mega_build_cmd(adapter_t *adapter, Scsi_Cmnd *cmd, int *busy) mega_passthru *pthru; scb_t *scb; mbox_t *mbox; - long seg; + u32 seg; char islogical; int max_ldrv_num; int channel = 0; @@ -858,7 +858,7 @@ mega_build_cmd(adapter_t *adapter, Scsi_Cmnd *cmd, int *busy) /* Calculate Scatter-Gather info */ mbox->m_out.numsgelements = mega_build_sglist(adapter, scb, - (u32 *)&mbox->m_out.xferaddr, (u32 *)&seg); + (u32 *)&mbox->m_out.xferaddr, &seg); return scb; |