mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
PM: Split up sysdev_[suspend|resume] from device_power_[down|up]
Move the sysdev_suspend/resume from the callee to the callers, with no real change in semantics, so that we can rework the disabling of interrupts during suspend/hibernation. This is based on an earlier patch from Linus. Signed-off-by: Rafael J. Wysocki <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
936577c61d
commit
770824bdc4
8 changed files with 38 additions and 7 deletions
|
|
@ -45,6 +45,13 @@ static int xen_suspend(void *data)
|
|||
err);
|
||||
return err;
|
||||
}
|
||||
err = sysdev_suspend(PMSG_SUSPEND);
|
||||
if (err) {
|
||||
printk(KERN_ERR "xen_suspend: sysdev_suspend failed: %d\n",
|
||||
err);
|
||||
device_power_up(PMSG_RESUME);
|
||||
return err;
|
||||
}
|
||||
|
||||
xen_mm_pin_all();
|
||||
gnttab_suspend();
|
||||
|
|
@ -61,6 +68,7 @@ static int xen_suspend(void *data)
|
|||
gnttab_resume();
|
||||
xen_mm_unpin_all();
|
||||
|
||||
sysdev_resume();
|
||||
device_power_up(PMSG_RESUME);
|
||||
|
||||
if (!*cancelled) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue