Re: [PATCH] sched/fair: Add missing unthrottle_cfs_rq()

2019-08-23 Thread Liangyan
Resend. Sorry that my previous email has format issue. On 19/8/23 上午2:48, bseg...@google.com wrote: Valentin Schneider writes: Turns out a cfs_rq->runtime_remaining can become positive in assign_cfs_rq_runtime(), but this codepath has no call to unthrottle_cfs_rq(). This can leave us in a s

Re: [PATCH] sched/fair: Add missing unthrottle_cfs_rq()

2019-08-22 Thread Valentin Schneider
On 22/08/2019 21:40, Valentin Schneider wrote: > On 22/08/2019 19:48, bseg...@google.com wrote: Re we shouldn't get account_cfs_rq_runtime() called on throttled cfs_rq's, with this: --- diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 171eef3f08f9..1acb88024cad 100644 --- a/kernel/sche

Re: [PATCH] sched/fair: Add missing unthrottle_cfs_rq()

2019-08-22 Thread Valentin Schneider
On 22/08/2019 19:48, bseg...@google.com wrote:> Having now seen the rest of the thread: > > Could you send the repro, as it doesn't seem to have reached lkml, so > that I can confirm my guess as to what's going on? > Huh, odd. Here's the thing: delay.c: #include #include #include #include

Re: [PATCH] sched/fair: Add missing unthrottle_cfs_rq()

2019-08-22 Thread bsegall
Valentin Schneider writes: > Turns out a cfs_rq->runtime_remaining can become positive in > assign_cfs_rq_runtime(), but this codepath has no call to > unthrottle_cfs_rq(). > > This can leave us in a situation where we have a throttled cfs_rq with > positive ->runtime_remaining, which breaks the

Re: [PATCH] sched/fair: Add missing unthrottle_cfs_rq()

2019-08-22 Thread bsegall
Peter Zijlstra writes: > On Tue, Aug 20, 2019 at 11:54:20AM +0100, Valentin Schneider wrote: >> Turns out a cfs_rq->runtime_remaining can become positive in >> assign_cfs_rq_runtime(), but this codepath has no call to >> unthrottle_cfs_rq(). >> >> This can leave us in a situation where we have a

Re: [PATCH] sched/fair: Add missing unthrottle_cfs_rq()

2019-08-22 Thread Peter Zijlstra
On Tue, Aug 20, 2019 at 11:54:20AM +0100, Valentin Schneider wrote: > Turns out a cfs_rq->runtime_remaining can become positive in > assign_cfs_rq_runtime(), but this codepath has no call to > unthrottle_cfs_rq(). > > This can leave us in a situation where we have a throttled cfs_rq with > positiv

[PATCH] sched/fair: Add missing unthrottle_cfs_rq()

2019-08-20 Thread Valentin Schneider
Turns out a cfs_rq->runtime_remaining can become positive in assign_cfs_rq_runtime(), but this codepath has no call to unthrottle_cfs_rq(). This can leave us in a situation where we have a throttled cfs_rq with positive ->runtime_remaining, which breaks the math in distribute_cfs_runtime(): this f