diff options
Diffstat (limited to 'kernel/power/disk.c')
-rw-r--r-- | kernel/power/disk.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/kernel/power/disk.c b/kernel/power/disk.c index fb8de63c2919..3ec789c6b537 100644 --- a/kernel/power/disk.c +++ b/kernel/power/disk.c | |||
@@ -16,6 +16,8 @@ | |||
16 | #include <linux/device.h> | 16 | #include <linux/device.h> |
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> | ||
20 | |||
19 | #include "power.h" | 21 | #include "power.h" |
20 | 22 | ||
21 | 23 | ||
@@ -234,6 +236,16 @@ static int software_resume(void) | |||
234 | { | 236 | { |
235 | int error; | 237 | int error; |
236 | 238 | ||
239 | if (!swsusp_resume_device) { | ||
240 | if (!strlen(resume_file)) | ||
241 | return -ENOENT; | ||
242 | swsusp_resume_device = name_to_dev_t(resume_file); | ||
243 | pr_debug("swsusp: Resume From Partition %s\n", resume_file); | ||
244 | } else { | ||
245 | pr_debug("swsusp: Resume From Partition %d:%d\n", | ||
246 | MAJOR(swsusp_resume_device), MINOR(swsusp_resume_device)); | ||
247 | } | ||
248 | |||
237 | if (noresume) { | 249 | if (noresume) { |
238 | /** | 250 | /** |
239 | * FIXME: If noresume is specified, we need to find the partition | 251 | * FIXME: If noresume is specified, we need to find the partition |