diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2019-02-01 01:47:53 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-02-01 10:04:08 +0100 |
commit | 5db25c9eb893df8f6b93c1d97b8006d768e1b6f5 (patch) | |
tree | b4a98023165114a5539d9804089fb1f4493e4caa /drivers/base/power/runtime.c | |
parent | driver core: Avoid careless re-use of existing device links (diff) | |
download | linux-dev-5db25c9eb893df8f6b93c1d97b8006d768e1b6f5.tar.xz linux-dev-5db25c9eb893df8f6b93c1d97b8006d768e1b6f5.zip |
driver core: Do not resume suppliers under device_links_write_lock()
It is incorrect to call pm_runtime_get_sync() under
device_links_write_lock(), because it may end up trying to take
device_links_read_lock() while resuming the target device and that
will deadlock in the non-SRCU case, so avoid that by resuming the
supplier device in device_link_add() before calling
device_links_write_lock().
Fixes: 21d5c57b3726 ("PM / runtime: Use device links")
Fixes: baa8809f6097 ("PM / runtime: Optimize the use of device links")
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions