lkml.org 
[lkml]   [2022]   [Sep]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH v3 4/6] sched/completion: Add wait_for_completion_state()
On Wed, Sep 07, 2022 at 09:35:20AM +0200, Ingo Molnar wrote:
> That's not actually true: there's ~7 functions in kernel/sched/completion.c
> with local variables, and only ~2 have this minor stylistic inconsistency
> right now AFAICS. Scheduler-wide the ratio is even lower.
>
> So even if a patch doesn't entirely remove the residual noise, let's not
> add to it, please?


--- a/kernel/sched/completion.c
+++ b/kernel/sched/completion.c
@@ -204,6 +204,7 @@ EXPORT_SYMBOL(wait_for_completion_io_tim
int __sched wait_for_completion_interruptible(struct completion *x)
{
long t = wait_for_common(x, MAX_SCHEDULE_TIMEOUT, TASK_INTERRUPTIBLE);
+
if (t == -ERESTARTSYS)
return t;
return 0;
@@ -241,6 +242,7 @@ EXPORT_SYMBOL(wait_for_completion_interr
int __sched wait_for_completion_killable(struct completion *x)
{
long t = wait_for_common(x, MAX_SCHEDULE_TIMEOUT, TASK_KILLABLE);
+
if (t == -ERESTARTSYS)
return t;
return 0;
@@ -250,6 +252,7 @@ EXPORT_SYMBOL(wait_for_completion_killab
int __sched wait_for_completion_state(struct completion *x, unsigned int state)
{
long t = wait_for_common(x, MAX_SCHEDULE_TIMEOUT, state);
+
if (t == -ERESTARTSYS)
return t;
return 0;
\
 
 \ /
  Last update: 2022-09-07 11:24    [W:0.270 / U:0.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site