Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

usb: renesas_usbhs: fix build warning if 64-bit architecture

This patch fixes the following warning if 64-bit architecture environment:

./drivers/usb/renesas_usbhs/common.c:496:25: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
dparam->type = of_id ? (u32)of_id->data : 0;

Acked-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>

authored by

Yoshihiro Shimoda and committed by
Felipe Balbi
9ae7ce00 7022cfdf

+2 -2
+1 -1
drivers/usb/renesas_usbhs/common.c
··· 493 493 return NULL; 494 494 495 495 dparam = &info->driver_param; 496 - dparam->type = of_id ? (u32)of_id->data : 0; 496 + dparam->type = of_id ? (uintptr_t)of_id->data : 0; 497 497 if (!of_property_read_u32(dev->of_node, "renesas,buswait", &tmp)) 498 498 dparam->buswait_bwait = tmp; 499 499 gpio = of_get_named_gpio_flags(dev->of_node, "renesas,enable-gpio", 0,
+1 -1
include/linux/usb/renesas_usbhs.h
··· 157 157 */ 158 158 int pio_dma_border; /* default is 64byte */ 159 159 160 - u32 type; 160 + uintptr_t type; 161 161 u32 enable_gpio; 162 162 163 163 /*