mirror of
https://github.com/linux-msm/laptops-kernel.git
synced 2026-08-13 14:19:53 -07:00
usb: typec: ucsi: Schedule connector worker on freezable workqueue
Currently, the UCSI connector worker is scheduled on the non-freezable system workqueue. During system suspend, on a plug/unplug event, the worker can run before the devices have actually resumed. The UCSI instances can implement operations that might need to do some HW accesses while the devices are still suspended. Scheduling the USCI connector worker on the freezable system workqueue instead will ensure the devices are resumed by the time the worker is scheduled to run. Signed-off-by: Abel Vesa <abel.vesa@linaro.org> Link: https://patch.msgid.link/20250205-ucsi-schedule-conn-worker-on-freezable-wq-v1-1-107d1356b77b@linaro.org Signed-off-by: Abel Vesa <abel.vesa@oss.qualcomm.com>
This commit is contained in:
@@ -1574,7 +1574,7 @@ void ucsi_connector_change(struct ucsi *ucsi, u8 num)
|
||||
con = &ucsi->connector[num - 1];
|
||||
|
||||
if (!test_and_set_bit(EVENT_PENDING, &ucsi->flags))
|
||||
schedule_work(&con->work);
|
||||
queue_work(system_freezable_wq, &con->work);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(ucsi_connector_change);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user