lkml.org 
[lkml]   [2018]   [May]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH v2 2/2] locking/percpu-rwsem: Mark rwsem as non-spinnable in percpu_rwsem_release()
On Tue, May 15, 2018 at 09:57:44AM -0400, Waiman Long wrote:
> > Afaict the whole .owner=NULL thing in release already stops the spinners
> > dead, and the above 'fixes' the debug splat. And this avoids exposing
> > that horrible interface and keeps the mucking private to
> > rwsem/percpu_rwsem.
>
> Actually setting owner to NULL does not stop spinning. The code just
> assume that the lock is going to be freed and spin in the outer loop. We
> need some special value to indicate that spinning should be stopped. How
> about just exposing a special value for that in linux/rwsem.h? Any
> suggestion for a good name?

RWSEM_NO_OWNER

\
 
 \ /
  Last update: 2018-05-15 16:01    [W:0.089 / U:2.616 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site