aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJeff Layton <jlayton@redhat.com>2011-12-25 18:29:55 -0500
committerRafael J. Wysocki <rjw@sisk.pl>2011-12-26 19:06:33 -0500
commitb3b73ec0d7fe5bf8f950232aa58dfa0416a62372 (patch)
treebeaf2eea7573acb110fe1159c032885b40e56ee7 /include
parent467de1fc67d1bd2954eaac7019c564f28fa2b6a5 (diff)
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: Jeff Layton <jlayton@redhat.com> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Diffstat (limited to 'include')
-rw-r--r--include/linux/freezer.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/linux/freezer.h b/include/linux/freezer.h
index 7bcfe73d999b..0ab54e16a91f 100644
--- a/include/linux/freezer.h
+++ b/include/linux/freezer.h
@@ -116,9 +116,11 @@ static inline int freezer_should_skip(struct task_struct *p)
116/* Like schedule_timeout_killable(), but should not block the freezer. */ 116/* Like schedule_timeout_killable(), but should not block the freezer. */
117#define freezable_schedule_timeout_killable(timeout) \ 117#define freezable_schedule_timeout_killable(timeout) \
118({ \ 118({ \
119 long __retval; \
119 freezer_do_not_count(); \ 120 freezer_do_not_count(); \
120 schedule_timeout_killable(timeout); \ 121 __retval = schedule_timeout_killable(timeout); \
121 freezer_count(); \ 122 freezer_count(); \
123 __retval; \
122}) 124})
123 125
124/* 126/*