Re: [patch] sched: signedness bug in yield_to()

2014-05-23 Thread Raghavendra KT
On Fri, May 23, 2014 at 3:50 PM, Dan Carpenter wrote: > yield_to() is supposed to return -ESRCH if there is no task to > yield to, but because the type is bool that is the same as returning > true. > > The only place I see which cares is kvm_vcpu_on_spin(). > > Signed-off-by: Dan Carpenter Thank

Re: [patch] sched: signedness bug in yield_to()

2014-05-23 Thread Peter Zijlstra
On Fri, May 23, 2014 at 01:20:42PM +0300, Dan Carpenter wrote: > yield_to() is supposed to return -ESRCH if there is no task to > yield to, but because the type is bool that is the same as returning > true. > > The only place I see which cares is kvm_vcpu_on_spin(). > > Signed-off-by: Dan Carpent

[patch] sched: signedness bug in yield_to()

2014-05-23 Thread Dan Carpenter
yield_to() is supposed to return -ESRCH if there is no task to yield to, but because the type is bool that is the same as returning true. The only place I see which cares is kvm_vcpu_on_spin(). Signed-off-by: Dan Carpenter diff --git a/include/linux/sched.h b/include/linux/sched.h index 9112646

[patch] sched: signedness bug in yield_to()

2013-02-05 Thread Dan Carpenter
In 7b270f6099 "sched: Bail out of yield_to when source and target runqueue has one task" we changed this to store -ESRCH so it needs to be signed. Signed-off-by: Dan Carpenter diff --git a/kernel/sched/core.c b/kernel/sched/core.c index 3e7b280..7ba7ea5 100644 --- a/kernel/sched/core.c +++ b/ker