From 30e7040f118850cf264a9bbdde6bd9a252ac6330 Mon Sep 17 00:00:00 2001 From: Kano Date: Sat, 9 Mar 2013 13:56:52 +1100 Subject: [PATCH] usb_cleanup() without locking --- usbutils.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/usbutils.c b/usbutils.c index 52226851..7aed305e 100644 --- a/usbutils.c +++ b/usbutils.c @@ -1567,8 +1567,12 @@ void usb_cleanup() struct cgpu_info *cgpu; int i; + hotplug_time = 0; + + nmsleep(10); + for (i = 0; i < total_devices; i++) { - cgpu = get_devices(i); + cgpu = devices[i]; switch (cgpu->drv->drv_id) { case DRIVER_BFLSC: case DRIVER_BITFORCE: