mirror of
https://github.com/apache/nuttx.git
synced 2026-06-12 22:24:12 +08:00
Fix USB hub bugs: Don't allocate port EP0 until needed, otherwise run out of endpoints; using wrong pointer to access child endpoint array in a few places
This commit is contained in:
@@ -3154,13 +3154,13 @@ struct usbhost_connection_s *lpc17_usbhost_initialize(int controller)
|
||||
|
||||
/* Initialize the public port representation */
|
||||
|
||||
hport = &priv->rhport.hport;
|
||||
hport->drvr = drvr;
|
||||
hport = &priv->rhport.hport;
|
||||
hport->drvr = drvr;
|
||||
#ifdef CONFIG_USBHOST_HUB
|
||||
hport->parent = NULL;
|
||||
hport->parent = NULL;
|
||||
#endif
|
||||
hport->ep0 = EDCTRL;
|
||||
hport->speed = USB_SPEED_FULL;
|
||||
hport->ep0 = EDCTRL;
|
||||
hport->speed = USB_SPEED_FULL;
|
||||
|
||||
/* Initialize function address generation logic */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user