mirror of
https://github.com/apache/nuttx.git
synced 2026-09-27 18:58:27 +08:00
drivers/usbhost/husbhost_max3421e.c: Corret how VBUS power is controlled.
This commit is contained in:
@@ -4705,7 +4705,8 @@ max3421e_usbhost_initialize(FAR const struct max3421e_lowerhalf_s *lower)
|
||||
int ret;
|
||||
|
||||
DEBUGASSERT(lower != NULL && lower->spi != NULL && lower->attach != NULL &&
|
||||
lower->attach != NULL && lower->acknowledge != NULL);
|
||||
lower->attach != NULL && lower->acknowledge != NULL &&
|
||||
lower->power != NULL);
|
||||
|
||||
/* Allocate and instance of the MAX4321E state structure */
|
||||
|
||||
@@ -4737,7 +4738,15 @@ max3421e_usbhost_initialize(FAR const struct max3421e_lowerhalf_s *lower)
|
||||
goto errout_with_alloc;
|
||||
}
|
||||
|
||||
/* Enable interrupts at the interrupt controller */
|
||||
/* Drive Vbus +5V (the smoke test).
|
||||
*
|
||||
* REVISIT: Should be done elsewhere in order to support device self-
|
||||
* powered mode? How does the MAX3421E VBUS detect logic work?
|
||||
*/
|
||||
|
||||
lower->power(lower, true);
|
||||
|
||||
/* Enable host interrupts */
|
||||
|
||||
lower->enable(lower, true);
|
||||
return &conn->conn;
|
||||
|
||||
Reference in New Issue
Block a user