lkml.org 
[lkml]   [2013]   [May]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/4] sys: remove unnecesscary parameter of set_one_prio
On Thu, 30 May 2013 01:08:25 -0700 Joe Perches <joe@perches.com> wrote:

> On Thu, 2013-05-30 at 15:58 +0800, liguang wrote:
> []
> > diff --git a/kernel/sys.c b/kernel/sys.c
> []
> > -static int set_one_prio(struct task_struct *p, int niceval, int error)
> > +static int set_one_prio(struct task_struct *p, int niceval)
>
> Umm, error is forwarded through do_each loops.
>
> Are you sure you can do this without
> changing any return code behaviors?

yes, you're right. The first time around, -ESRCH gets rewritten to 0
and the zero propagates, as long as nobody hits an error which isn't
-ESRCH. I'm not sure this was the most straightforward possible
implementation :(



\
 
 \ /
  Last update: 2013-06-01 01:21    [W:2.071 / U:0.120 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site