2018-08-02 13:17:53

by Ajay Singh

[permalink] [raw]
Subject: [PATCH] staging: wilc1000: fix compilation warning for ARCH PowerPC

Fix below warning reported for PowerPC arch compilation

include/uapi/linux/byteorder/big_endian.h:95:37: warning: passing
argument 1 of '__swab32s' makes pointer from integer without a cast
[-Wint-conversion]

Fixes: 02211edc9a1f ("staging: wilc1000: fix endianness warnings
reported by sparse")

Signed-off-by: Ajay Singh <[email protected]>
---
drivers/staging/wilc1000/wilc_sdio.c | 2 +-
drivers/staging/wilc1000/wilc_spi.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/wilc1000/wilc_sdio.c b/drivers/staging/wilc1000/wilc_sdio.c
index 8bda550..1908afa1 100644
--- a/drivers/staging/wilc1000/wilc_sdio.c
+++ b/drivers/staging/wilc1000/wilc_sdio.c
@@ -563,7 +563,7 @@ static int sdio_read_reg(struct wilc *wilc, u32 addr, u32 *data)
}
}

- le32_to_cpus(*data);
+ le32_to_cpus(data);

return 1;

diff --git a/drivers/staging/wilc1000/wilc_spi.c b/drivers/staging/wilc1000/wilc_spi.c
index 064892d..a85f87b 100644
--- a/drivers/staging/wilc1000/wilc_spi.c
+++ b/drivers/staging/wilc1000/wilc_spi.c
@@ -699,7 +699,7 @@ static int spi_internal_read(struct wilc *wilc, u32 adr, u32 *data)
return 0;
}

- le32_to_cpus(*data);
+ le32_to_cpus(data);

return 1;
}
@@ -778,7 +778,7 @@ static int wilc_spi_read_reg(struct wilc *wilc, u32 addr, u32 *data)
return 0;
}

- le32_to_cpus(*data);
+ le32_to_cpus(data);

return 1;
}
--
2.7.4


2018-08-02 21:23:54

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH] staging: wilc1000: fix compilation warning for ARCH PowerPC

On Thu, Aug 02, 2018 at 04:57:02PM +0530, Ajay Singh wrote:
> Fix below warning reported for PowerPC arch compilation
>
> include/uapi/linux/byteorder/big_endian.h:95:37: warning: passing
> argument 1 of '__swab32s' makes pointer from integer without a cast
> [-Wint-conversion]
>
> Fixes: 02211edc9a1f ("staging: wilc1000: fix endianness warnings
> reported by sparse")
>
> Signed-off-by: Ajay Singh <[email protected]>
> ---

You forgot the reported-by: line :(

I'll go add it, but be more careful in the future please.

greg k-h

2018-08-03 06:24:29

by Ajay Singh

[permalink] [raw]
Subject: Re: [PATCH] staging: wilc1000: fix compilation warning for ARCH PowerPC

Hi Greg,

On Thu, 2 Aug 2018 21:31:16 +0200
Greg KH <[email protected]> wrote:

> On Thu, Aug 02, 2018 at 04:57:02PM +0530, Ajay Singh wrote:
> > Fix below warning reported for PowerPC arch compilation
> >
> > include/uapi/linux/byteorder/big_endian.h:95:37: warning: passing
> > argument 1 of '__swab32s' makes pointer from integer without a cast
> > [-Wint-conversion]
> >
> > Fixes: 02211edc9a1f ("staging: wilc1000: fix endianness warnings
> > reported by sparse")
> >
> > Signed-off-by: Ajay Singh <[email protected]>
> > ---
>
> You forgot the reported-by: line :(
>

Sorry for the trouble.

> I'll go add it, but be more careful in the future please.
>

Thank you for adding it up. I will take care in future patches.

Regards,
Ajay