Commit b3b73ec0 authored by Jeff Layton's avatar Jeff Layton Committed by Rafael J. Wysocki

PM / Freezer: fix return value of freezable_schedule_timeout_killable()

...it should return the return code from schedule_timeout_killable(),
not the one from freezer_count().

All of the current callers ignore the return code so the bug is
harmless but it's worth fixing.
Signed-off-by: default avatarJeff Layton <jlayton@redhat.com>
Signed-off-by: default avatarRafael J. Wysocki <rjw@sisk.pl>
parent 467de1fc
......@@ -116,9 +116,11 @@ static inline int freezer_should_skip(struct task_struct *p)
/* Like schedule_timeout_killable(), but should not block the freezer. */
#define freezable_schedule_timeout_killable(timeout) \
({ \
long __retval; \
freezer_do_not_count(); \
schedule_timeout_killable(timeout); \
__retval = schedule_timeout_killable(timeout); \
freezer_count(); \
__retval; \
})
/*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment