summaryrefslogtreecommitdiffstats
path: root/kernel/power/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/power/main.c')
-rw-r--r--kernel/power/main.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/kernel/power/main.c b/kernel/power/main.c
index 8812985f3029..fc45ed22620f 100644
--- a/kernel/power/main.c
+++ b/kernel/power/main.c
@@ -15,7 +15,6 @@
#include <linux/delay.h>
#include <linux/errno.h>
#include <linux/init.h>
-#include <linux/pm.h>
#include <linux/console.h>
#include <linux/cpu.h>
#include <linux/resume-trace.h>
@@ -97,6 +96,11 @@ static int suspend_prepare(suspend_state_t state)
}
}
+ if (pm_ops->set_target) {
+ error = pm_ops->set_target(state);
+ if (error)
+ goto Thaw;
+ }
suspend_console();
error = device_suspend(PMSG_SUSPEND);
if (error) {
OpenPOWER on IntegriCloud