]> git.baikalelectronics.ru Git - kernel.git/commit
PM: sleep: Do not let "syscore" devices runtime-suspend during system transitions
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 22 Oct 2021 12:58:23 +0000 (14:58 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 22 Oct 2021 16:09:58 +0000 (18:09 +0200)
commit024a0ed7c89a08ac1e80aa07d66c6d644dc195f4
tree3e2533861449ddcfc5dac654c5f67154d13ef4a2
parent5594984d5faec8b8cecd71eb451f5ef6fcc66e51
PM: sleep: Do not let "syscore" devices runtime-suspend during system transitions

There is no reason to allow "syscore" devices to runtime-suspend
during system-wide PM transitions, because they are subject to the
same possible failure modes as any other devices in that respect.

Accordingly, change device_prepare() and device_complete() to call
pm_runtime_get_noresume() and pm_runtime_put(), respectively, for
"syscore" devices too.

Fixes: 908ff7a48a00 ("Merge branch 'pm-sleep'")
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Cc: 3.10+ <stable@vger.kernel.org> # 3.10+
Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/base/power/main.c