1
0
Fork 0
alistair23-linux/kernel/power
Rafael J. Wysocki 62109b4317 PM / sleep: Fix test_suspend= command line option
After commit d431cbc53c (PM / sleep: Simplify sleep states sysfs
interface code) the pm_states[] array is not populated initially,
which causes setup_test_suspend() to always fail and the suspend
testing during boot doesn't work any more.

Fix the problem by using pm_labels[] instead of pm_states[] in
setup_test_suspend() and storing a pointer to the label of the
sleep state to test rather than the number representing it,
because the connection between the state numbers and labels is
only established by suspend_set_ops().

Fixes: d431cbc53c (PM / sleep: Simplify sleep states sysfs interface code)
Reported-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2014-09-03 01:21:03 +02:00
..
Kconfig PM / OPP: Remove ARCH_HAS_OPP 2014-07-23 00:51:30 +02:00
Makefile PM / Sleep: Add user space interface for manipulating wakeup sources, v3 2012-05-01 21:26:05 +02:00
autosleep.c PM / Sleep: avoid 'autosleep' in shutdown progress 2013-07-15 01:31:37 +02:00
block_io.c block: Abstract out bvec iterator 2013-11-23 22:33:47 -08:00
console.c arm, pm, vmpressure: add missing slab.h includes 2014-02-03 13:24:01 -05:00
hibernate.c PM / Sleep: Remove ftrace_stop/start() from suspend and hibernate 2014-07-17 09:45:06 -04:00
main.c Merge branches 'pm-apm' and 'pm-sleep' 2014-07-27 23:56:30 +02:00
power.h PM / sleep: Fix test_suspend= command line option 2014-09-03 01:21:03 +02:00
poweroff.c power/sysrq: fix inconstistent help message of sysrq key 2013-04-30 17:04:10 -07:00
process.c PM / sleep: Fix request_firmware() error at resume 2014-07-15 14:27:29 +02:00
qos.c PM / QoS: Introcuce latency tolerance device PM QoS type 2014-02-11 00:35:38 +01:00
snapshot.c PM / hibernate: avoid unsafe pages in e820 reserved regions 2014-08-06 23:50:07 +02:00
suspend.c PM / sleep: Fix test_suspend= command line option 2014-09-03 01:21:03 +02:00
suspend_test.c PM / sleep: Fix test_suspend= command line option 2014-09-03 01:21:03 +02:00
swap.c PM / hibernate: fixed typo in comment 2014-06-01 00:23:07 +02:00
user.c PM / hibernate: introduce "nohibernate" boot parameter 2014-06-16 23:29:39 +02:00
wakelock.c PM / wakeup: Include appropriate header file in kernel/power/wakelock.c 2014-03-01 01:02:09 +01:00