lkml.org 
[lkml]   [2019]   [Apr]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v4 08/16] locking/rwsem: Make rwsem_spin_on_owner() return owner state
On Wed, Apr 17, 2019 at 02:29:02PM -0400, Waiman Long wrote:
> On 04/17/2019 08:47 AM, Peter Zijlstra wrote:
> >>
> >> enum owner_state {
> >> OWNER_NULL = 1 << 0,
> >> OWNER_WRITER = 1 << 1,
> >> OWNER_READER = 1 << 2,
> >> OWNER_NONSPINNABLE = 1 << 3,
> >> };
> >> #define OWNER_SPINNABLE (OWNER_NULL | OWNER_WRITER)
> > Hmm, we should not spin on OWNER_NULL. Or at least not mixed in with the
> > patch that changes the shape of all this. That should go in the RT
> > thingy patch, which comes after this.
>
> We do spin on OWNER_NULL right now, not in rwsem_spin_on_owner() but in
> the main rwsem_optimistic_spin() function.
>
> RT task will quit if owner is NULL.

Yeah, I figured it out eventually :-)

\
 
 \ /
  Last update: 2019-04-18 10:41    [W:0.206 / U:0.092 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site