summaryrefslogtreecommitdiff
path: root/kernel/power
diff options
context:
space:
mode:
authorMyungJoo Ham <myungjoo.ham@samsung.com>2011-04-22 22:00:54 +0200
committerRafael J. Wysocki <rjw@sisk.pl>2011-05-17 23:19:16 +0200
commit3c431936087e93d2219a184a8e19eaa68077e379 (patch)
tree65b9bd696100c808ae02d6c235990a2c4fbb7104 /kernel/power
parentc1d10d18c542278b7fbc413c289d3cb6219da6b3 (diff)
PM / Suspend: Do not ignore error codes returned by suspend_enter()
The current implementation of suspend-to-RAM returns 0 if there is an error from suspend_enter(), because suspend_devices_and_enter() ignores the return value from suspend_enter(). This patch addresses this issue and properly keep the error return from suspend_enter() and let suspend_devices_and_enter relay the error return. Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Diffstat (limited to 'kernel/power')
-rw-r--r--kernel/power/suspend.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/power/suspend.c b/kernel/power/suspend.c
index 6275970b2189..fa9fabd12eff 100644
--- a/kernel/power/suspend.c
+++ b/kernel/power/suspend.c
@@ -226,7 +226,7 @@ int suspend_devices_and_enter(suspend_state_t state)
if (suspend_test(TEST_DEVICES))
goto Recover_platform;
- suspend_enter(state);
+ error = suspend_enter(state);
Resume_devices:
suspend_test_start();