summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>2026-11-06 12:31:41 +0100
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2026-11-06 19:05:08 +0100
commit55b2b8af704f845e01fa2f31ee259b07641ce3a9 (patch)
tree11ea9afb2ddc74024aebafe98b1e7efcc554294a /include/linux
parent7a93f7e30a3f7c8dd4f5fe4cde54d01c8018e2bc (diff)
downloadlinux-55b2b8af704f845e01fa2f31ee259b07641ce3a9.tar.gz
linux-55b2b8af704f845e01fa2f31ee259b07641ce3a9.zip
PM: runtime: Update last_busy in rpm_resume() for active devices
Setting an autosuspend delay for a device can be expected to cause a runtime suspend of the device after calling, say, pm_runtime_put() to be deferred, so the time between the last successful attempt to resume the device and its subsequent suspend is at least equal to the autosuspend delay. However, that expectation is only met after the device has been actually resumed in rpm_resume() by invoking its runtime resume callback. If the runtime PM status of the device is already "active" when rpm_resume() runs for it, the device's last_busy timestamp is not updated which may allow a subsequent pm_runtime_put() invocation (or similar) to suspend it right away. This is arguably inconsistent and confusing, so make rpm_resume() also update the device's last_busy timestamp when it finds that the device is already "active" and it is about to return 1 early. Fixes: 56f487c78015 ("PM / Runtime: Update last_busy in rpm_resume") Link: https://lore.kernel.org/linux-pm/CAJZ5v0jTX1FgeS9FCV=+V4uacSgLQBVsSPnU27ybgUGg57GUOA@mail.gmail.com/ Reported-by: Brian Norris <briannorris@chromium.org> Cc: All applicable <stable@vger.kernel.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Reviewed-by: Brian Norris <briannorris@chromium.org> Tested-by: Brian Norris <briannorris@chromium.org> Link: https://patch.msgid.link/13032301.O9o76ZdvQC@rafael.j.wysocki Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'include/linux')
0 files changed, 0 insertions, 0 deletions