Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
USB: ohci-hcd.c: Add spinlock when disabling OHCI interrupts in ohci_…
…shutdown This patch is used for fixing 'irq nobody care' issue during reboot How to reproduce: 1)Prepare weston enabled environment 2)Connect USB mouse 3)Read input from the mouse and reboot $ od -tx /dev/input/event0 & $ reboot 4)Move the mouse while system shutdown Don't need to move the mouse after "reboot: Restarting system" 5)Repeat step 3 and step 4 until below error occurs Error log: usb 2-1: USB disconnect, device number 2 irq 156: nobody cared (try booting with the "irqpoll" option) Workqueue: usb_hub_wq hub_event Call trace: ... usbhid_disconnect+0x4c/0x78 usb_unbind_interface+0x6c/0x2a8 device_release_driver_internal+0x174/0x208 device_release_driver+0x14/0x20 bus_remove_device+0x114/0x128 device_del+0x1ac/0x300 usb_disable_device+0x8c/0x200 usb_disconnect+0xb4/0x218 ... handlers: usb_hcd_irq Disabling IRQ xen-troops#156 This issue occurs due to race condition between ohci_irq() interrupt handler and ohci_shutdown() Adding spin_lock_irq() to prevent interrupt raising while ohci is shutting down can fix this issue. When host controller dies, lock will be held by io_watchdog_func before ohci_shutdown, so locking should be skipped in this case to prevent deadlock Signed-off-by: Tho Vu <tho.vu.wh@rvc.renesas.com>
- Loading branch information