linux/drivers/usb
Xu Yang cc509b6a47 usb: chipidea: core: handle power lost in workqueue
When power is recycled in usb controller during system power management,
the controller will recognize it and switch role if role has been changed
during power lost. In current design, it will be completed in resume()
function. However, this may bring issues since usb class devices have
their pm operations too and these device's resume() functions are still
not being called at this point. When usb controller recognized host role
should be stopped, these usb class devices will be removed at this point.
But these usb class devices can't be removed in some cases, such as scsi
devices. Since scsi driver may sync data to U-disk, however it will block
there because scsi drvier can only handle pm request when is in suspended
state. Therefore, there may exist a dependency between ci_resume() and usb
class device's resume(). To break this potential dependency, we need to
handle power lost work in a workqueue.

Fixes: 74494b3321 ("usb: chipidea: core: add controller resume support when controller is powered off")
cc: stable@vger.kernel.org
Signed-off-by: Xu Yang <xu.yang_2@nxp.com>
Link: https://lore.kernel.org/r/20240119123537.3614838-1-xu.yang_2@nxp.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-01-27 16:39:14 -08:00
..
atm usb: ueagle-atm: Use wait_event_freezable_timeout() in uea_wait() 2024-01-04 15:57:29 +01:00
c67x00 USB: c67x00: Remove unused declaration c67x00_hcd_msg_received() 2023-10-02 16:42:33 +02:00
cdns3 usb: cdns3: Fix uvc fail when DMA cross 4k boundery since sg enabled 2024-01-04 16:01:45 +01:00
chipidea usb: chipidea: core: handle power lost in workqueue 2024-01-27 16:39:14 -08:00
class usb: cdc-acm: return correct error code on unsupported break 2023-12-15 13:52:47 +01:00
common Merge 6.5-rc6 into usb-next 2023-08-14 22:22:31 +02:00
core usb: core: Prevent null pointer dereference in update_port_device_state 2024-01-27 16:38:39 -08:00
dwc2 usb: dwc2: Disable clock gating feature on Rockchip SoCs 2024-01-02 14:35:23 +01:00
dwc3 usb: dwc3: gadget: Fix NULL pointer dereference in dwc3_gadget_suspend 2024-01-27 16:39:03 -08:00
early usb: early: xhci-dbc: Use memcpy_and_pad() 2023-01-31 10:40:54 +01:00
fotg210 USB / Thunderbolt changes for 6.8-rc1 2024-01-18 11:43:55 -08:00
gadget usb: gadget: ncm: Fix endianness of wMaxSegmentSize variable in ecm_desc 2024-01-27 16:28:28 -08:00
host xhci: handle isoc Babble and Buffer Overrun events properly 2024-01-27 16:28:35 -08:00
image scsi: usb: uas: Declare two host templates and host template pointers const 2023-03-24 19:20:00 -04:00
isp1760 usb: isp1760: Convert to platform remove callback returning void 2023-05-28 12:38:01 +01:00
misc USB: core: Use device_driver directly in struct usb_driver and usb_device_driver 2024-01-04 16:06:32 +01:00
mon usb: mon: Fix atomicity violation in mon_bin_vma_fault 2024-01-05 10:36:08 +01:00
mtu3 usb: mtu3: Convert to platform remove callback returning void 2023-10-21 12:49:08 +02:00
musb Merge 6.6-rc6 into usb-next 2023-10-16 17:36:12 +02:00
phy usb: phy: mxs: remove CONFIG_USB_OTG condition for mxs_phy_is_otg_host() 2024-01-04 16:01:56 +01:00
renesas_usbhs usb: Explicitly include correct DT includes 2023-07-25 18:20:02 +02:00
roles USB: roles: make role_class a static const structure 2023-06-20 16:20:40 +02:00
serial USB / Thunderbolt changes for 6.8-rc1 2024-01-18 11:43:55 -08:00
storage USB / Thunderbolt changes for 6.8-rc1 2024-01-18 11:43:55 -08:00
typec USB / Thunderbolt changes for 6.8-rc1 2024-01-18 11:43:55 -08:00
usbip USB: core: Use device_driver directly in struct usb_driver and usb_device_driver 2024-01-04 16:06:32 +01:00
Kconfig usb: pci-quirks: handle HAS_IOPORT dependency for AMD quirk 2023-10-02 16:19:12 +02:00
Makefile usb: host: u132-hcd: Delete driver 2023-03-21 14:06:11 +01:00
usb-skeleton.c