Skip to contentSkip to conversation

usb: r8a66597: Fix initilization size of r8a66597 info structure

PATCH New Yasuhisa Umano 2 participants 3 messages Apr 18, 2014 – Jun 25, 2014 USB

lore
Share & tools
lore
#0 lore raw

PATCH v2 2/2 usb: r8a66597: Fix initilization size of r8a66597 info structure

Initialization of r8a66597 info structure is not enough. Because initilization was used size of pointer. This fixes that use size of r8a6659 info structure.

---
v2 : Change from sizeof(struct r8a66597) to sizeof(*r8a66597)

 drivers/usb/host/r8a66597-hcd.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/host/r8a66597-hcd.c +0 -0
index c58d2a9..5114544 100644
@@ -807,7 +807,7 @@ int usb_lowlevel_init(int index, enum usb_init_type init,

void **controller)

R8A66597_DPRINT("%s\n", __func__);

- memset(r8a66597, 0, sizeof(r8a66597));
+ memset(r8a66597, 0, sizeof(*r8a66597));
r8a66597->reg = CONFIG_R8A66597_BASE_ADDR;

disable_controller(r8a66597);

Signature · 1 line
1.7.9.5
#1 lore raw

PATCH v2 2/2 usb: r8a66597: Fix initilization size of r8a66597 info structure

Quoted 5 lines · Yasuhisa Umano

Initialization of r8a66597 info structure is not enough. Because initilization was used size of pointer. This fixes that use size of r8a6659 info structure.

It's in u-boot-usb/master , please double-check if all is correct there. Thanks!

Best regards,
Marek Vasut

#2 lore raw

PATCH v2 2/2 usb: r8a66597: Fix initilization size of r8a66597 info structure

In reply to Yasuhisa Umano
Quoted 5 lines · Yasuhisa Umano

Initialization of r8a66597 info structure is not enough. Because initilization was used size of pointer. This fixes that use size of r8a6659 info structure.

I'm not sure how those two patches disappeared from my radar. Sorry about that, applied, thank you.

Best regards,
Marek Vasut