# This is a BitKeeper generated patch for the following project:
# Project Name: Linux kernel tree
# This patch format is intended for GNU patch command version 2.5 or higher.
# This patch includes the following deltas:
# ChangeSet 1.388 -> 1.389
# drivers/usb/uhci.c 1.24 -> 1.25
#
# The following is the BitKeeper ChangeSet Log
# --------------------------------------------
# 02/04/08 [EMAIL PROTECTED] 1.389
# [PATCH] uhci.c 2.4.19-pre6 SMP deadlock
#
# This patch fixes a bug reported by Greg and David, as well as some other
# people recently.
#
# uhci.c would call wait_ms, which can sleep, with spinlocks held. There
# are two places where this happens, but only one was the cause of the
# problem.
#
# Greg, please apply to 2.4 and 2.5. Thanks!
#
# JE
# --------------------------------------------
#
diff -Nru a/drivers/usb/uhci.c b/drivers/usb/uhci.c
--- a/drivers/usb/uhci.c Mon Apr 8 09:45:43 2002
+++ b/drivers/usb/uhci.c Mon Apr 8 09:45:43 2002
@@ -1811,6 +1811,9 @@
} else {
urb->status = -ENOENT;
+ spin_unlock(&urb->lock);
+ spin_unlock_irqrestore(&uhci->urb_list_lock, flags);
+
if (in_interrupt()) { /* wait at least 1 frame */
static int errorcount = 10;
@@ -1820,9 +1823,6 @@
} else
schedule_timeout(1+1*HZ/1000);
- spin_unlock(&urb->lock);
- spin_unlock_irqrestore(&uhci->urb_list_lock, flags);
-
uhci_call_completion(urb);
}
}
@@ -2193,12 +2193,12 @@
OK(0);
case RH_PORT_RESET:
SET_RH_PORTSTAT(USBPORTSC_PR);
- wait_ms(50); /* USB v1.1 7.1.7.3 */
+ mdelay(50); /* USB v1.1 7.1.7.3 */
uhci->rh.c_p_r[wIndex - 1] = 1;
CLR_RH_PORTSTAT(USBPORTSC_PR);
udelay(10);
SET_RH_PORTSTAT(USBPORTSC_PE);
- wait_ms(10);
+ mdelay(10);
SET_RH_PORTSTAT(0xa);
OK(0);
case RH_PORT_POWER:
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel