power: Avoids bogus error messages for the suspend aborts.
Avoids printing bogus error message "tasks refusing to freeze", in cases where pending wakeup source caused the suspend abort. Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com> Change-Id: I913ad290f501b31cd536d039834c8d24c6f16928
This commit is contained in:
parent
8774e7626b
commit
1adb5b4034
1 changed files with 7 additions and 6 deletions
|
@ -83,15 +83,17 @@ static int try_to_freeze_tasks(bool user_only)
|
||||||
do_div(elapsed_msecs64, NSEC_PER_MSEC);
|
do_div(elapsed_msecs64, NSEC_PER_MSEC);
|
||||||
elapsed_msecs = elapsed_msecs64;
|
elapsed_msecs = elapsed_msecs64;
|
||||||
|
|
||||||
if (todo) {
|
if (wakeup) {
|
||||||
pr_cont("\n");
|
pr_cont("\n");
|
||||||
pr_err("Freezing of tasks %s after %d.%03d seconds "
|
pr_err("Freezing of tasks aborted after %d.%03d seconds",
|
||||||
"(%d tasks refusing to freeze, wq_busy=%d):\n",
|
elapsed_msecs / 1000, elapsed_msecs % 1000);
|
||||||
wakeup ? "aborted" : "failed",
|
} else if (todo) {
|
||||||
|
pr_cont("\n");
|
||||||
|
pr_err("Freezing of tasks failed after %d.%03d seconds"
|
||||||
|
" (%d tasks refusing to freeze, wq_busy=%d):\n",
|
||||||
elapsed_msecs / 1000, elapsed_msecs % 1000,
|
elapsed_msecs / 1000, elapsed_msecs % 1000,
|
||||||
todo - wq_busy, wq_busy);
|
todo - wq_busy, wq_busy);
|
||||||
|
|
||||||
if (!wakeup) {
|
|
||||||
read_lock(&tasklist_lock);
|
read_lock(&tasklist_lock);
|
||||||
for_each_process_thread(g, p) {
|
for_each_process_thread(g, p) {
|
||||||
if (p != current && !freezer_should_skip(p)
|
if (p != current && !freezer_should_skip(p)
|
||||||
|
@ -99,7 +101,6 @@ static int try_to_freeze_tasks(bool user_only)
|
||||||
sched_show_task(p);
|
sched_show_task(p);
|
||||||
}
|
}
|
||||||
read_unlock(&tasklist_lock);
|
read_unlock(&tasklist_lock);
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
pr_cont("(elapsed %d.%03d seconds) ", elapsed_msecs / 1000,
|
pr_cont("(elapsed %d.%03d seconds) ", elapsed_msecs / 1000,
|
||||||
elapsed_msecs % 1000);
|
elapsed_msecs % 1000);
|
||||||
|
|
Loading…
Add table
Reference in a new issue