Skip to content
This repository has been archived by the owner on Nov 8, 2023. It is now read-only.

Commit

Permalink
PM: Check dpm_suspend_start() return code during partial resume
Browse files Browse the repository at this point in the history
Bug: 24986869

Change-Id: Iea3e0f84e43827b365b96d34bc647e310523bd40
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Signed-off-by: Thierry Strudel <tstrudel@google.com>
  • Loading branch information
Dmitry Shmidt authored and Thierry Strudel committed Nov 3, 2015
1 parent ed37c62 commit f14ede6
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion kernel/power/suspend.c
Original file line number Diff line number Diff line change
Expand Up @@ -252,8 +252,14 @@ static bool suspend_again(bool *drivers_resumed)
if (suspend_again_consensus() &&
!freeze_kernel_threads()) {
clear_wakeup_reasons();
dpm_suspend_start(PMSG_SUSPEND);
*drivers_resumed = false;
if (dpm_suspend_start(PMSG_SUSPEND)) {
printk(KERN_ERR "PM: Some devices failed to suspend\n");
log_suspend_abort_reason("Some devices failed to suspend");
if (suspend_ops->recover)
suspend_ops->recover();
return false;
}
return true;
}

Expand Down

0 comments on commit f14ede6

Please sign in to comment.