Re: [RFC PATCH v3 10/16] sched: Core-wide rq->lock

2019-05-31 Thread Vineeth Pillai
> > I'm confused, how doesn't this break the invariant above? > > That is, all CPUs must at all times agree on the value of rq_lockp(), > and I'm not seeing how that is true with the above changes. > While fixing the crash in cpu online/offline, I was focusing on maintaining the invariance of all o

Re: [RFC PATCH v3 10/16] sched: Core-wide rq->lock

2019-05-31 Thread Peter Zijlstra
On Wed, May 29, 2019 at 08:36:46PM +, Vineeth Remanan Pillai wrote: > + * The static-key + stop-machine variable are needed such that: > + * > + * spin_lock(rq_lockp(rq)); > + * ... > + * spin_unlock(rq_lockp(rq)); > + * > + * ends up locking and unlocking the _same_ lock, and all CPUs >

[RFC PATCH v3 10/16] sched: Core-wide rq->lock

2019-05-29 Thread Vineeth Remanan Pillai
From: Peter Zijlstra Introduce the basic infrastructure to have a core wide rq->lock. Signed-off-by: Peter Zijlstra (Intel) Signed-off-by: Julien Desfossez Signed-off-by: Vineeth Remanan Pillai --- Changes in v3 - - Fixes a crash during cpu offline/offline with coresched enabled