Re: [RFC PATCH 6/7] locking/rtqspinlock: Voluntarily yield CPU when need_sched()

2017-01-05 Thread Daniel Bristot de Oliveira
On 01/03/2017 07:00 PM, Waiman Long wrote: > For nested spinlock with outer lock acquired, it will > + * boost its priority to the highest RT priority level to try to acquire the > + * inner lock, finish up its work, release the locks and reenable preemption. DL scheduler turns the definition of

Re: [RFC PATCH 6/7] locking/rtqspinlock: Voluntarily yield CPU when need_sched()

2017-01-04 Thread Waiman Long
On 01/04/2017 05:07 AM, Boqun Feng wrote: > On Tue, Jan 03, 2017 at 01:00:29PM -0500, Waiman Long wrote: >> Ideally we want the CPU to be preemptible even when inside or waiting >> for a lock. We cannot make it preemptible when inside a lock critical >> section, but we can try to make the task volu

Re: [RFC PATCH 6/7] locking/rtqspinlock: Voluntarily yield CPU when need_sched()

2017-01-04 Thread Boqun Feng
On Tue, Jan 03, 2017 at 01:00:29PM -0500, Waiman Long wrote: > Ideally we want the CPU to be preemptible even when inside or waiting > for a lock. We cannot make it preemptible when inside a lock critical > section, but we can try to make the task voluntarily yield the CPU > when waiting for a lock

[RFC PATCH 6/7] locking/rtqspinlock: Voluntarily yield CPU when need_sched()

2017-01-03 Thread Waiman Long
Ideally we want the CPU to be preemptible even when inside or waiting for a lock. We cannot make it preemptible when inside a lock critical section, but we can try to make the task voluntarily yield the CPU when waiting for a lock. This patch checks the need_sched() flag and yields the CPU when th