diff options
Diffstat (limited to 'payloads/libpayload')
-rw-r--r-- | payloads/libpayload/drivers/usb/ohci.c | 2 | ||||
-rw-r--r-- | payloads/libpayload/drivers/usb/ohci_rh.c | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/payloads/libpayload/drivers/usb/ohci.c b/payloads/libpayload/drivers/usb/ohci.c index b128029751..ad5638c5dd 100644 --- a/payloads/libpayload/drivers/usb/ohci.c +++ b/payloads/libpayload/drivers/usb/ohci.c @@ -205,6 +205,7 @@ ohci_stop (hci_t *controller) // TODO: turn off all operation of OHCI } +#if 0 static void dump_td(td_t *cur, int level) { @@ -216,6 +217,7 @@ dump_td(td_t *cur, int level) usb_debug("%s toggle: %x\n", spc, !!(cur->config & TD_TOGGLE_DATA1)); #endif } +#endif static int wait_for_ed(usbdev_t *dev, ed_t *head, int pages) diff --git a/payloads/libpayload/drivers/usb/ohci_rh.c b/payloads/libpayload/drivers/usb/ohci_rh.c index eb3e10b26c..9de2b981f8 100644 --- a/payloads/libpayload/drivers/usb/ohci_rh.c +++ b/payloads/libpayload/drivers/usb/ohci_rh.c @@ -48,8 +48,8 @@ ohci_rh_enable_port (usbdev_t *dev, int port) * After reset, the port will be enabled automatically (ohci spec * 7.4.4). */ - int delay = 100; /* 100 * 500us == 50ms */ - while (delay > 0) { + int total_delay = 100; /* 100 * 500us == 50ms */ + while (total_delay > 0) { if (!(OHCI_INST(dev->controller)->opreg->HcRhPortStatus[port] & CurrentConnectStatus)) return; @@ -61,7 +61,7 @@ ohci_rh_enable_port (usbdev_t *dev, int port) while ((OHCI_INST (dev->controller)->opreg->HcRhPortStatus[port] & PortResetStatus) && timeout--) { - udelay(500); delay--; + udelay(500); total_delay--; } if (OHCI_INST (dev->controller)->opreg->HcRhPortStatus[port] & PortResetStatus) { |