diff options
Diffstat (limited to 'kernel/power/user.c')
-rw-r--r-- | kernel/power/user.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/kernel/power/user.c b/kernel/power/user.c index 89443b85163b..f7b7a785a5c6 100644 --- a/kernel/power/user.c +++ b/kernel/power/user.c | |||
@@ -57,7 +57,7 @@ static int snapshot_open(struct inode *inode, struct file *filp) | |||
57 | memset(&data->handle, 0, sizeof(struct snapshot_handle)); | 57 | memset(&data->handle, 0, sizeof(struct snapshot_handle)); |
58 | if ((filp->f_flags & O_ACCMODE) == O_RDONLY) { | 58 | if ((filp->f_flags & O_ACCMODE) == O_RDONLY) { |
59 | data->swap = swsusp_resume_device ? | 59 | data->swap = swsusp_resume_device ? |
60 | swap_type_of(swsusp_resume_device, 0) : -1; | 60 | swap_type_of(swsusp_resume_device, 0, NULL) : -1; |
61 | data->mode = O_RDONLY; | 61 | data->mode = O_RDONLY; |
62 | } else { | 62 | } else { |
63 | data->swap = -1; | 63 | data->swap = -1; |
@@ -268,7 +268,8 @@ static int snapshot_ioctl(struct inode *inode, struct file *filp, | |||
268 | * so we need to recode them | 268 | * so we need to recode them |
269 | */ | 269 | */ |
270 | if (old_decode_dev(arg)) { | 270 | if (old_decode_dev(arg)) { |
271 | data->swap = swap_type_of(old_decode_dev(arg), 0); | 271 | data->swap = swap_type_of(old_decode_dev(arg), |
272 | 0, NULL); | ||
272 | if (data->swap < 0) | 273 | if (data->swap < 0) |
273 | error = -ENODEV; | 274 | error = -ENODEV; |
274 | } else { | 275 | } else { |
@@ -365,7 +366,7 @@ static int snapshot_ioctl(struct inode *inode, struct file *filp, | |||
365 | swdev = old_decode_dev(swap_area.dev); | 366 | swdev = old_decode_dev(swap_area.dev); |
366 | if (swdev) { | 367 | if (swdev) { |
367 | offset = swap_area.offset; | 368 | offset = swap_area.offset; |
368 | data->swap = swap_type_of(swdev, offset); | 369 | data->swap = swap_type_of(swdev, offset, NULL); |
369 | if (data->swap < 0) | 370 | if (data->swap < 0) |
370 | error = -ENODEV; | 371 | error = -ENODEV; |
371 | } else { | 372 | } else { |