diff options
Diffstat (limited to 'kernel/power/disk.c')
-rw-r--r-- | kernel/power/disk.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/kernel/power/disk.c b/kernel/power/disk.c index 2d8bf054d036..761956e813f5 100644 --- a/kernel/power/disk.c +++ b/kernel/power/disk.c | |||
@@ -17,12 +17,12 @@ | |||
17 | #include <linux/delay.h> | 17 | #include <linux/delay.h> |
18 | #include <linux/fs.h> | 18 | #include <linux/fs.h> |
19 | #include <linux/mount.h> | 19 | #include <linux/mount.h> |
20 | #include <linux/pm.h> | ||
20 | 21 | ||
21 | #include "power.h" | 22 | #include "power.h" |
22 | 23 | ||
23 | 24 | ||
24 | extern suspend_disk_method_t pm_disk_mode; | 25 | extern suspend_disk_method_t pm_disk_mode; |
25 | extern struct pm_ops * pm_ops; | ||
26 | 26 | ||
27 | extern int swsusp_suspend(void); | 27 | extern int swsusp_suspend(void); |
28 | extern int swsusp_write(void); | 28 | extern int swsusp_write(void); |
@@ -49,13 +49,11 @@ dev_t swsusp_resume_device; | |||
49 | 49 | ||
50 | static void power_down(suspend_disk_method_t mode) | 50 | static void power_down(suspend_disk_method_t mode) |
51 | { | 51 | { |
52 | unsigned long flags; | ||
53 | int error = 0; | 52 | int error = 0; |
54 | 53 | ||
55 | local_irq_save(flags); | ||
56 | switch(mode) { | 54 | switch(mode) { |
57 | case PM_DISK_PLATFORM: | 55 | case PM_DISK_PLATFORM: |
58 | device_shutdown(); | 56 | kernel_power_off_prepare(); |
59 | error = pm_ops->enter(PM_SUSPEND_DISK); | 57 | error = pm_ops->enter(PM_SUSPEND_DISK); |
60 | break; | 58 | break; |
61 | case PM_DISK_SHUTDOWN: | 59 | case PM_DISK_SHUTDOWN: |