Title: [9048] trunk/drivers/usb/musb/blackfin.c: [6142] Fix restart timer handler logic, add seperate disconnect interrupt judgement to recognize the repluged USB device.
Revision
9048
Author
lliubbo
Date
2010-08-04 07:25:58 -0400 (Wed, 04 Aug 2010)

Log Message

[6142] Fix restart timer handler logic, add seperate disconnect interrupt judgement to recognize the repluged USB device.

Modified Paths

Diff

Modified: trunk/drivers/usb/musb/blackfin.c (9047 => 9048)


--- trunk/drivers/usb/musb/blackfin.c	2010-08-04 11:02:52 UTC (rev 9047)
+++ trunk/drivers/usb/musb/blackfin.c	2010-08-04 11:25:58 UTC (rev 9048)
@@ -171,8 +171,9 @@
 	}
 
 	/* Start sampling ID pin, when plug is removed from MUSB */
-	if ((musb->xceiv->state == OTG_STATE_B_IDLE ||
-			musb->xceiv->state == OTG_STATE_A_WAIT_BCON)) {
+	if ((is_otg_enabled(musb) && (musb->xceiv->state == OTG_STATE_B_IDLE
+		|| musb->xceiv->state == OTG_STATE_A_WAIT_BCON)) ||
+		(musb->int_usb & MUSB_INTR_DISCONNECT)) {
 		mod_timer(&musb_conn_timer, jiffies + TIMER_DELAY);
 		musb->a_wait_bcon = TIMER_DELAY;
 	}
_______________________________________________
Linux-kernel-commits mailing list
[email protected]
https://blackfin.uclinux.org/mailman/listinfo/linux-kernel-commits

Reply via email to