diff options
Diffstat (limited to 'kernel/power')
-rw-r--r-- | kernel/power/block_io.c | 2 | ||||
-rw-r--r-- | kernel/power/console.c | 1 | ||||
-rw-r--r-- | kernel/power/hibernate.c | 7 | ||||
-rw-r--r-- | kernel/power/snapshot.c | 2 |
4 files changed, 7 insertions, 5 deletions
diff --git a/kernel/power/block_io.c b/kernel/power/block_io.c index d09dd10c5a5e..9a58bc258810 100644 --- a/kernel/power/block_io.c +++ b/kernel/power/block_io.c | |||
@@ -32,7 +32,7 @@ static int submit(int rw, struct block_device *bdev, sector_t sector, | |||
32 | struct bio *bio; | 32 | struct bio *bio; |
33 | 33 | ||
34 | bio = bio_alloc(__GFP_WAIT | __GFP_HIGH, 1); | 34 | bio = bio_alloc(__GFP_WAIT | __GFP_HIGH, 1); |
35 | bio->bi_sector = sector; | 35 | bio->bi_iter.bi_sector = sector; |
36 | bio->bi_bdev = bdev; | 36 | bio->bi_bdev = bdev; |
37 | bio->bi_end_io = end_swap_bio_read; | 37 | bio->bi_end_io = end_swap_bio_read; |
38 | 38 | ||
diff --git a/kernel/power/console.c b/kernel/power/console.c index eacb8bd8cab4..aba9c545a0e3 100644 --- a/kernel/power/console.c +++ b/kernel/power/console.c | |||
@@ -9,6 +9,7 @@ | |||
9 | #include <linux/kbd_kern.h> | 9 | #include <linux/kbd_kern.h> |
10 | #include <linux/vt.h> | 10 | #include <linux/vt.h> |
11 | #include <linux/module.h> | 11 | #include <linux/module.h> |
12 | #include <linux/slab.h> | ||
12 | #include "power.h" | 13 | #include "power.h" |
13 | 14 | ||
14 | #define SUSPEND_CONSOLE (MAX_NR_CONSOLES-1) | 15 | #define SUSPEND_CONSOLE (MAX_NR_CONSOLES-1) |
diff --git a/kernel/power/hibernate.c b/kernel/power/hibernate.c index 0121dab83f43..37170d4dd9a6 100644 --- a/kernel/power/hibernate.c +++ b/kernel/power/hibernate.c | |||
@@ -82,6 +82,7 @@ void hibernation_set_ops(const struct platform_hibernation_ops *ops) | |||
82 | 82 | ||
83 | unlock_system_sleep(); | 83 | unlock_system_sleep(); |
84 | } | 84 | } |
85 | EXPORT_SYMBOL_GPL(hibernation_set_ops); | ||
85 | 86 | ||
86 | static bool entering_platform_hibernation; | 87 | static bool entering_platform_hibernation; |
87 | 88 | ||
@@ -293,10 +294,10 @@ static int create_image(int platform_mode) | |||
293 | error); | 294 | error); |
294 | /* Restore control flow magically appears here */ | 295 | /* Restore control flow magically appears here */ |
295 | restore_processor_state(); | 296 | restore_processor_state(); |
296 | if (!in_suspend) { | 297 | if (!in_suspend) |
297 | events_check_enabled = false; | 298 | events_check_enabled = false; |
298 | platform_leave(platform_mode); | 299 | |
299 | } | 300 | platform_leave(platform_mode); |
300 | 301 | ||
301 | Power_up: | 302 | Power_up: |
302 | syscore_resume(); | 303 | syscore_resume(); |
diff --git a/kernel/power/snapshot.c b/kernel/power/snapshot.c index b38109e204af..d9f61a145802 100644 --- a/kernel/power/snapshot.c +++ b/kernel/power/snapshot.c | |||
@@ -637,7 +637,7 @@ __register_nosave_region(unsigned long start_pfn, unsigned long end_pfn, | |||
637 | BUG_ON(!region); | 637 | BUG_ON(!region); |
638 | } else | 638 | } else |
639 | /* This allocation cannot fail */ | 639 | /* This allocation cannot fail */ |
640 | region = alloc_bootmem(sizeof(struct nosave_region)); | 640 | region = memblock_virt_alloc(sizeof(struct nosave_region), 0); |
641 | region->start_pfn = start_pfn; | 641 | region->start_pfn = start_pfn; |
642 | region->end_pfn = end_pfn; | 642 | region->end_pfn = end_pfn; |
643 | list_add_tail(®ion->list, &nosave_regions); | 643 | list_add_tail(®ion->list, &nosave_regions); |