mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-06 15:01:35 +00:00
g: enable usb wakeup interrupts
To make sure cr50 usb works, we need to disable sleep immediately after the usb controller detects that usb has resumed. The usb WKUPINT is asserted on usb resume, but cr50 doesn't currently respond to that. This change umasks the usb wakeup interrupt, so that USB ISR will disable sleep on resume. BUG=b:35774906 BRANCH=none TEST=Run 100 'usb_updater -f' 100 times sleeping 20 seconds in between each run. Verify there are no failures and cr50 still goes to sleep between each run. Change-Id: I1819deaa3988bcf2a85686d1b9d57092ba264c4d Signed-off-by: Mary Ruthven <mruthven@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/450900 Reviewed-by: Vadim Bendebury <vbendeb@google.com>
This commit is contained in:
@@ -1347,8 +1347,8 @@ void usb_init(void)
|
||||
GINTMSK(RESETDET) | /* TODO: Do we need this? */
|
||||
/* Idle, Suspend detected. Should go to sleep. */
|
||||
GINTMSK(ERLYSUSP) | GINTMSK(USBSUSP) |
|
||||
/* Watch for first SOF */
|
||||
GINTMSK(SOF);
|
||||
/* Watch for first SOF and usb wakeup */
|
||||
GINTMSK(SOF) | GINTMSK(WKUPINT);
|
||||
|
||||
/* Device registers have been setup */
|
||||
GR_USB_DCTL |= DCTL_PWRONPRGDONE;
|
||||
|
||||
Reference in New Issue
Block a user