Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 61543
b: refs/heads/master
c: b1457bc
h: refs/heads/master
i:
  61541: 5a73c97
  61539: 64a81ed
  61535: 8fe5d1e
v: v3
  • Loading branch information
Rafael J. Wysocki authored and Linus Torvalds committed Jul 19, 2007
1 parent f1eba35 commit 16b9846
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 10a1803d667e209914eaada9b95525252f23ec78
refs/heads/master: b1457bcc3a00a0446c7f6e2f22fd24b6d8d0a309
15 changes: 13 additions & 2 deletions trunk/kernel/power/disk.c
Original file line number Diff line number Diff line change
Expand Up @@ -205,12 +205,23 @@ int hibernation_restore(int platform_mode)

int hibernation_platform_enter(void)
{
int error;

if (hibernation_ops) {
kernel_shutdown_prepare(SYSTEM_SUSPEND_DISK);
return hibernation_ops->enter();
/*
* We have cancelled the power transition by running
* hibernation_ops->finish() before saving the image, so we
* should let the firmware know that we're going to enter the
* sleep state after all
*/
error = hibernation_ops->prepare();
if (!error)
error = hibernation_ops->enter();
} else {
return -ENOSYS;
error = -ENOSYS;
}
return error;
}

/**
Expand Down

0 comments on commit 16b9846

Please sign in to comment.