linux-stable/drivers/usb/chipidea
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
..
bits.h
ci.h usb: chipidea: core: handle power lost in workqueue 2024-01-27 16:39:14 -08:00
ci_hdrc_imx.c usb: chipidea: ci_hdrc_imx: add wakeup clock and keep it always on 2024-01-04 16:01:56 +01:00
ci_hdrc_imx.h
ci_hdrc_msm.c
ci_hdrc_npcm.c usb: chipidea: Add support for NPCM 2023-10-21 12:46:00 +02:00
ci_hdrc_pci.c
ci_hdrc_tegra.c usb: chipidea: tegra: Consistently use dev_err_probe() 2023-10-02 14:10:47 +02:00
ci_hdrc_usb2.c usb: chipidea: Fix unused ci_hdrc_usb2_of_match warning for !CONFIG_OF 2023-10-21 12:46:35 +02:00
core.c usb: chipidea: core: handle power lost in workqueue 2024-01-27 16:39:14 -08:00
debug.c
host.c
host.h
Kconfig usb: chipidea: Add support for NPCM 2023-10-21 12:46:00 +02:00
Makefile usb: chipidea: Add support for NPCM 2023-10-21 12:46:00 +02:00
otg.c usb: chipidea: add CI_HDRC_FORCE_VBUS_ACTIVE_ALWAYS flag 2023-10-21 12:45:45 +02:00
otg.h
otg_fsm.c
otg_fsm.h
trace.c
trace.h
udc.c usb: chipidea: udc: Add revision check of 2.20[CI_REVISION_22] 2023-11-22 12:02:53 +00:00
udc.h
ulpi.c
usbmisc_imx.c