Title: [3965] trunk/drivers/usb/musb/musb_core.c: [#3740] fix workqueue BUG()
error when no USB device plugged in the port of BF54x
- Revision
- 3965
- Author
- cooloney
- Date
- 2007-11-30 01:26:25 -0600 (Fri, 30 Nov 2007)
Log Message
[#3740] fix workqueue BUG() error when no USB device plugged in the port of BF54x
Move IRQ workqueue init before request_irq, otherwise host SUSPEND irq
will call schedule_work() and BUG_ON() will fire because musb_irq_work did
not initialised.
Diffstat
musb_core.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
Modified Paths
Diff
Modified: trunk/drivers/usb/musb/musb_core.c (3964 => 3965)
--- trunk/drivers/usb/musb/musb_core.c 2007-11-30 07:16:01 UTC (rev 3964)
+++ trunk/drivers/usb/musb/musb_core.c 2007-11-30 07:26:25 UTC (rev 3965)
@@ -2039,6 +2039,9 @@
if (status < 0)
goto fail2;
+ /* Init IRQ workqueue before request_irq */
+ INIT_WORK(&musb->irq_work, musb_irq_work);
+
/* attach to the IRQ */
if (request_irq (nIrq, musb->isr, 0, dev->bus_id, musb)) {
dev_err(dev, "request_irq %d failed!\n", nIrq);
@@ -2118,8 +2121,6 @@
return status;
}
- INIT_WORK(&musb->irq_work, musb_irq_work);
-
#ifdef CONFIG_SYSFS
status = device_create_file(dev, &dev_attr_mode);
status = device_create_file(dev, &dev_attr_vbus);
_______________________________________________
Linux-kernel-commits mailing list
[email protected]
http://blackfin.uclinux.org/mailman/listinfo/linux-kernel-commits