* [U-Boot] [PATCH] fs: usbifs: Fix warning in ubifs
@ 2017-05-30 12:29 Michal Simek
2017-06-06 5:10 ` Heiko Schocher
0 siblings, 1 reply; 2+ messages in thread
From: Michal Simek @ 2017-05-30 12:29 UTC (permalink / raw)
To: u-boot
From: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
This patch fixes the below warning by typecasting it properly
fs/ubifs/ubifs.c: In function 'ubifs_load':
fs/ubifs/ubifs.c:942:29: warning: cast to pointer from integer
of different size [-Wint-to-pointer-cast]
err = ubifs_read(filename, (void *)addr, 0, size, &actread);
Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
---
fs/ubifs/ubifs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/ubifs/ubifs.c b/fs/ubifs/ubifs.c
index cc397d605b0e..db29489eca75 100644
--- a/fs/ubifs/ubifs.c
+++ b/fs/ubifs/ubifs.c
@@ -939,7 +939,7 @@ int ubifs_load(char *filename, u32 addr, u32 size)
printf("Loading file '%s' to addr 0x%08x...\n", filename, addr);
- err = ubifs_read(filename, (void *)addr, 0, size, &actread);
+ err = ubifs_read(filename, (void *)(uintptr_t)addr, 0, size, &actread);
if (err == 0) {
setenv_hex("filesize", actread);
printf("Done\n");
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [U-Boot] [PATCH] fs: usbifs: Fix warning in ubifs
2017-05-30 12:29 [U-Boot] [PATCH] fs: usbifs: Fix warning in ubifs Michal Simek
@ 2017-06-06 5:10 ` Heiko Schocher
0 siblings, 0 replies; 2+ messages in thread
From: Heiko Schocher @ 2017-06-06 5:10 UTC (permalink / raw)
To: u-boot
Hello Michal,
Am 30.05.2017 um 14:29 schrieb Michal Simek:
> From: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
>
> This patch fixes the below warning by typecasting it properly
> fs/ubifs/ubifs.c: In function 'ubifs_load':
> fs/ubifs/ubifs.c:942:29: warning: cast to pointer from integer
> of different size [-Wint-to-pointer-cast]
> err = ubifs_read(filename, (void *)addr, 0, size, &actread);
>
> Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
> ---
>
> fs/ubifs/ubifs.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Reviewed-by: Heiko Schocher <hs@denx.de>
bye,
Heiko
>
> diff --git a/fs/ubifs/ubifs.c b/fs/ubifs/ubifs.c
> index cc397d605b0e..db29489eca75 100644
> --- a/fs/ubifs/ubifs.c
> +++ b/fs/ubifs/ubifs.c
> @@ -939,7 +939,7 @@ int ubifs_load(char *filename, u32 addr, u32 size)
>
> printf("Loading file '%s' to addr 0x%08x...\n", filename, addr);
>
> - err = ubifs_read(filename, (void *)addr, 0, size, &actread);
> + err = ubifs_read(filename, (void *)(uintptr_t)addr, 0, size, &actread);
> if (err == 0) {
> setenv_hex("filesize", actread);
> printf("Done\n");
>
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-06-06 5:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-30 12:29 [U-Boot] [PATCH] fs: usbifs: Fix warning in ubifs Michal Simek
2017-06-06 5:10 ` Heiko Schocher
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.