linux/drivers/base/power
Rafael J. Wysocki 3775fc538f PM: sleep: core: Synchronize runtime PM status of parents and children
Commit 6e176bf8d4 ("PM: sleep: core: Do not skip callbacks in the
resume phase") overlooked the case in which the parent of a device with
DPM_FLAG_SMART_SUSPEND set did not use that flag and could be runtime-
suspended before a transition into a system-wide sleep state.  In that
case, if the child is resumed during the subsequent transition from
that state into the working state, its runtime PM status will be set to
RPM_ACTIVE, but the runtime PM status of the parent will not be updated
accordingly, even though the parent will be resumed too, because of the
dev_pm_skip_suspend() check in device_resume_noirq().

Address this problem by tracking the need to set the runtime PM status
to RPM_ACTIVE during system-wide resume transitions for devices with
DPM_FLAG_SMART_SUSPEND set and all of the devices depended on by them.

Fixes: 6e176bf8d4 ("PM: sleep: core: Do not skip callbacks in the resume phase")
Closes: https://lore.kernel.org/linux-pm/Z30p2Etwf3F2AUvD@hovoldconsulting.com/
Reported-by: Johan Hovold <johan@kernel.org>
Tested-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Johan Hovold <johan+linaro@kernel.org>
Tested-by: Johan Hovold <johan+linaro@kernel.org>
Link: https://patch.msgid.link/12619233.O9o76ZdvQC@rjwysocki.net
2025-01-29 11:50:33 +01:00
..
Makefile
clock_ops.c
common.c PM: domains: Support required OPPs in dev_pm_domain_attach_list() 2024-10-10 14:13:49 +02:00
generic_ops.c
main.c PM: sleep: core: Synchronize runtime PM status of parents and children 2025-01-29 11:50:33 +01:00
power.h
qos-test.c
qos.c PM: QoS: Export dev_pm_qos_read_value 2024-10-25 10:17:37 -05:00
runtime.c
sysfs.c PM: sleep: sysfs: don't include 'pm_wakeup.h' directly 2024-12-05 12:15:56 +01:00
trace.c
wakeirq.c PM: sleep: wakeirq: Introduce device-managed variant of dev_pm_set_wake_irq() 2025-01-17 20:27:46 +01:00
wakeup.c
wakeup_stats.c