Re: [PATCH 1/2] sched: Fix balance_callback()

2020-09-11 Thread peterz
On Fri, Sep 11, 2020 at 01:17:02PM +0100, Valentin Schneider wrote: > On 11/09/20 09:17, Peter Zijlstra wrote: > > The intent of balance_callback() has always been to delay executing > > balancing operations until the end of the current rq->lock section. > > This is because balance operations must

Re: [PATCH 1/2] sched: Fix balance_callback()

2020-09-11 Thread Valentin Schneider
On 11/09/20 13:25, pet...@infradead.org wrote: > On Fri, Sep 11, 2020 at 01:17:02PM +0100, Valentin Schneider wrote: >> So that can be say __schedule() tail racing with some setprio; what's the >> worst that can (currently) happen here? Something like say two consecutive >> enqueuing of push_rt_t

Re: [PATCH 1/2] sched: Fix balance_callback()

2020-09-11 Thread Valentin Schneider
On 11/09/20 09:17, Peter Zijlstra wrote: > The intent of balance_callback() has always been to delay executing > balancing operations until the end of the current rq->lock section. > This is because balance operations must often drop rq->lock, and that > isn't safe in general. > > However, as not

[PATCH 1/2] sched: Fix balance_callback()

2020-09-11 Thread Peter Zijlstra
The intent of balance_callback() has always been to delay executing balancing operations until the end of the current rq->lock section. This is because balance operations must often drop rq->lock, and that isn't safe in general. However, as noted by Scott, there were a few holes in that scheme; ba