ChangeSet 1.1735, 2004/05/17 15:35:00-07:00, oliver@neukum.org [PATCH] USB: purge wait_ms from core this makes the core use the new safe waiting helper. - remove wait_ms from hub driver drivers/usb/core/hub.c | 14 +++++++------- 1 files changed, 7 insertions(+), 7 deletions(-) diff -Nru a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c --- a/drivers/usb/core/hub.c Mon May 17 16:37:15 2004 +++ b/drivers/usb/core/hub.c Mon May 17 16:37:15 2004 @@ -381,7 +381,7 @@ } /* Wait for power to be enabled */ - wait_ms(hub->descriptor->bPwrOn2PwrGood * 2); + usb_uninterruptible_sleep_ms(hub->descriptor->bPwrOn2PwrGood * 2); } static int hub_hub_status(struct usb_hub *hub, @@ -887,7 +887,7 @@ delay_time < HUB_RESET_TIMEOUT; delay_time += delay) { /* wait to give the device a chance to reset */ - wait_ms(delay); + usb_uninterruptible_sleep_ms(delay); /* read and decode port status */ ret = hub_port_status(hub, port, &portstatus, &portchange); @@ -1002,7 +1002,7 @@ connection = 0; stable_count = 0; for (delay_time = 0; delay_time < HUB_DEBOUNCE_TIMEOUT; delay_time += HUB_DEBOUNCE_STEP) { - wait_ms(HUB_DEBOUNCE_STEP); + usb_uninterruptible_sleep_ms(HUB_DEBOUNCE_STEP); ret = hub_port_status(hub, port, &portstatus, &portchange); if (ret < 0) @@ -1146,7 +1146,7 @@ retval = usb_set_address(dev); if (retval >= 0) break; - wait_ms(200); + usb_uninterruptible_sleep_ms(200); } if (retval < 0) { dev_err(&dev->dev, @@ -1165,11 +1165,11 @@ * - let SET_ADDRESS settle, some device hardware wants it * - read ep0 maxpacket even for high and low speed, */ - wait_ms(10); + usb_uninterruptible_sleep_ms(10); retval = usb_get_device_descriptor(dev, 8); if (retval >= 8) break; - wait_ms(100); + usb_uninterruptible_sleep_ms(100); } if (retval != 8) { dev_err(&dev->dev, "device descriptor read/%s, error %d\n", @@ -1515,7 +1515,7 @@ } if (hubchange & HUB_CHANGE_OVERCURRENT) { dev_dbg (&hub->intf->dev, "overcurrent change\n"); - wait_ms(500); /* Cool down */ + usb_uninterruptible_sleep_ms(500); /* Cool down */ clear_hub_feature(dev, C_HUB_OVER_CURRENT); hub_power_on(hub); }