linux-stable/drivers/base
Rafael J. Wysocki 544e737dea PM: sleep: Fix error handling in dpm_prepare()
Commit 2aa36604e8 ("PM: sleep: Avoid calling put_device() under
dpm_list_mtx") forgot to update the while () loop termination
condition to also break the loop if error is nonzero, which
causes the loop to become infinite if device_prepare() returns
an error for one device.

Add the missing !error check.

Fixes: 2aa36604e8 ("PM: sleep: Avoid calling put_device() under dpm_list_mtx")
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reported-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org>
Cc: All applicable <stable@vger.kernel.org>
2021-12-17 18:36:08 +01:00
..
firmware_loader firmware_loader: move struct builtin_fw to the only place used 2021-10-22 14:13:53 +02:00
power PM: sleep: Fix error handling in dpm_prepare() 2021-12-17 18:36:08 +01:00
regmap Core: 2021-11-02 06:20:58 -07:00
test device property: build kunit tests without structleak plugin 2021-10-06 17:53:42 -06:00
Kconfig RISC-V Patches for the 5.12 Merge Window 2021-02-26 10:28:35 -08:00
Makefile mm/memory_hotplug: remove CONFIG_MEMORY_HOTPLUG_SPARSE 2021-11-06 13:30:42 -07:00
arch_numa.c memblock: use memblock_free for freeing virtual pointers 2021-11-06 13:30:41 -07:00
arch_topology.c arch_topology: Fix missing clear cluster_cpumask in remove_cpu_topology() 2021-11-11 13:09:33 +01:00
attribute_container.c driver core: attribute_container: fix W=1 warnings 2021-05-14 13:37:10 +02:00
auxiliary.c Merge 5.14-rc3 into driver-core-next 2021-07-27 09:22:08 +02:00
base.h software nodes: Split software_node_notify() 2021-07-16 19:17:05 +02:00
bus.c driver: base: Replace symbolic permissions with octal permissions 2021-07-21 14:56:00 +02:00
cacheinfo.c cacheinfo: clear cache_leaves(cpu) in free_cache_attributes() 2021-07-21 17:29:40 +02:00
class.c drivers: base: fix some kernel-doc markups 2020-11-09 18:56:49 +01:00
component.c component: do not leave master devres group open after bind 2021-10-21 13:01:56 +02:00
container.c
core.c driver core: Provide device_match_acpi_handle() helper 2021-10-20 19:38:29 +02:00
cpu.c driver: base: Prefer unsigned int to bare use of unsigned 2021-07-21 17:30:09 +02:00
dd.c Merge 5.14-rc5 into driver-core-next 2021-08-09 09:03:47 +02:00
devcoredump.c devcoredump: remove contact information 2021-06-04 15:05:44 +02:00
devres.c devres: Enable trace events 2021-06-15 17:14:36 +02:00
devtmpfs.c devtmpfs: actually reclaim some init memory 2021-03-23 14:57:35 +01:00
driver.c drivers: base: Convert to printk alias functions 2020-07-10 14:16:44 +02:00
firmware.c
hypervisor.c
init.c driver core: auxiliary bus: Fix calling stage for auxiliary bus init 2021-02-11 08:43:03 +01:00
isa.c bus: Make remove callback return void 2021-07-21 11:53:42 +02:00
map.c driver: base: Prefer unsigned int to bare use of unsigned 2021-07-21 17:30:09 +02:00
memory.c Merge branch 'akpm' (patches from Andrew) 2021-09-08 12:55:35 -07:00
module.c
node.c mm/memory_hotplug: remove CONFIG_MEMORY_HOTPLUG_SPARSE 2021-11-06 13:30:42 -07:00
pinctrl.c
platform-msi.c platform-msi: Add ABI to show msi_irqs of platform devices 2021-08-24 09:16:20 +02:00
platform.c driver core: platform: Make use of the helper macro SET_RUNTIME_PM_OPS() 2021-09-14 16:52:41 +02:00
property.c device property: move mac addr helpers to eth.c 2021-10-07 13:39:51 +01:00
soc.c soc: fix comment for freeing soc_dev_attr 2020-12-09 19:46:31 +01:00
swnode.c device property: Drop redundant NULL checks 2021-10-26 19:14:01 +02:00
syscore.c syscore: Use pm_pr_dbg() for syscore_{suspend,resume}() 2020-09-08 13:32:06 +02:00
topology.c topology: Represent clusters of CPUs within a die 2021-10-15 11:25:15 +02:00
trace.c devres: Enable trace events 2021-06-15 17:14:36 +02:00
trace.h devres: Enable trace events 2021-06-15 17:14:36 +02:00
transport_class.c scsi: drivers: base: Propagate errors through the transport component 2020-01-15 22:55:37 -05:00