summaryrefslogtreecommitdiff
path: root/payloads/libpayload/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'payloads/libpayload/drivers')
-rw-r--r--payloads/libpayload/drivers/usb/ohci.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/payloads/libpayload/drivers/usb/ohci.c b/payloads/libpayload/drivers/usb/ohci.c
index 8a01cf24fb..606e46791e 100644
--- a/payloads/libpayload/drivers/usb/ohci.c
+++ b/payloads/libpayload/drivers/usb/ohci.c
@@ -49,6 +49,13 @@ static void ohci_process_done_queue(ohci_t *ohci, int spew_debug);
static void
ohci_reset (hci_t *controller)
{
+ if (controller == NULL)
+ return;
+
+ OHCI_INST(controller)->opreg->HcCommandStatus = HostControllerReset;
+ mdelay(2); /* wait 2ms */
+ OCHI_INST(controller)->opreg->HcControl = 0;
+ mdelay(10); /* wait 10ms */
}
#ifdef USB_DEBUG