Re: [patch 13/17] drivers/scsi/initio.c: suppress compile warning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Mar 28, 2008 at 2:48 PM,  <akpm@xxxxxxxxxxxxxxxxxxxx> wrote:
> From: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
>
>  powerpc:
>
>  drivers/scsi/initio.c: In function 'initio_build_scb':
>  drivers/scsi/initio.c:2585: warning: large integer implicitly truncated to unsigned type

I posted a fix for this yesterday and Alan Cox ACKed it.

It's here:
    http://marc.info/?l=linux-scsi&m=120668352622659&w=2

hth,
grant

>
>  Cc: James Bottomley <James.Bottomley@xxxxxxxxxxxxxxxxxxxxx>
>  Cc: FUJITA Tomonori <fujita.tomonori@xxxxxxxxxxxxx>
>  Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
>  ---
>
>   drivers/scsi/initio.c |    6 +++++-
>   1 file changed, 5 insertions(+), 1 deletion(-)
>
>  diff -puN drivers/scsi/initio.c~drivers-scsi-initioc-suppress-compile-warning drivers/scsi/initio.c
>  --- a/drivers/scsi/initio.c~drivers-scsi-initioc-suppress-compile-warning
>  +++ a/drivers/scsi/initio.c
>  @@ -2582,7 +2582,11 @@ static void initio_build_scb(struct init
>         dma_addr = dma_map_single(&host->pci_dev->dev, cmnd->sense_buffer,
>                                   SENSE_SIZE, DMA_FROM_DEVICE);
>         cblk->senseptr = cpu_to_le32((u32)dma_addr);
>  -       cblk->senselen = cpu_to_le32(SENSE_SIZE);
>  +       /*
>  +        * The below needs casting to avoid a "large integer implicitly
>  +        * truncated to unsigned type" warning on powerpc
>  +        */
>  +       cblk->senselen = (u8)cpu_to_le32(SENSE_SIZE);
>         cmnd->SCp.ptr = (char *)(unsigned long)dma_addr;
>         cblk->cdblen = cmnd->cmd_len;
>
>  _
>  --
>  To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
>  the body of a message to majordomo@xxxxxxxxxxxxxxx
>  More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux