Re: [PATCH v2] sys_prctl(): remove unsigned comparision with less than zero

2019-07-30 Thread Yang Xu
on 2019/07/25 11:10, Yang Xu wrote: --- a/kernel/sys.c +++ b/kernel/sys.c @@ -2372,7 +2372,7 @@ SYSCALL_DEFINE5(prctl, int, option, unsigned long, arg2, unsigned long, arg3, error = current->timer_slack_ns; break; case PR_SET_TIMERSLACK: -if (arg2<= 0)

Re: [PATCH v2] sys_prctl(): remove unsigned comparision with less than zero

2019-07-24 Thread Yang Xu
on 2019/07/25 10:14, Andrew Morton wrote: On Wed, 24 Jul 2019 10:11:48 +0800 Yang Xu wrote: Currently, when calling prctl(PR_SET_TIMERSLACK, arg2), arg2 is an unsigned long value, arg2 will never< 0. Negative judgment is meaningless, so remove it. ... --- a/kernel/sys.c +++ b/kernel/sys.c

Re: [PATCH v2] sys_prctl(): remove unsigned comparision with less than zero

2019-07-24 Thread Andrew Morton
On Wed, 24 Jul 2019 10:11:48 +0800 Yang Xu wrote: > Currently, when calling prctl(PR_SET_TIMERSLACK, arg2), arg2 is an > unsigned long value, arg2 will never < 0. Negative judgment is > meaningless, so remove it. > > ... > > --- a/kernel/sys.c > +++ b/kernel/sys.c > @@ -2372,7 +2372,7 @@

Re: [PATCH v2] sys_prctl(): remove unsigned comparision with less than zero

2019-07-24 Thread Cyrill Gorcunov
On Wed, Jul 24, 2019 at 10:11:48AM +0800, Yang Xu wrote: > Currently, when calling prctl(PR_SET_TIMERSLACK, arg2), arg2 is an > unsigned long value, arg2 will never < 0. Negative judgment is > meaningless, so remove it. > > Fixes: 6976675d9404 ("hrtimer: create a "timer_slack" field in the task

[PATCH v2] sys_prctl(): remove unsigned comparision with less than zero

2019-07-23 Thread Yang Xu
Currently, when calling prctl(PR_SET_TIMERSLACK, arg2), arg2 is an unsigned long value, arg2 will never < 0. Negative judgment is meaningless, so remove it. Fixes: 6976675d9404 ("hrtimer: create a "timer_slack" field in the task struct") Signed-off-by: Yang Xu Cc: Cyrill Gorcunov ---