tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Adaptive RW locks



Hi,

On Mon, Jan 20, 2020 at 02:18:15PM +0900, Takashi YAMAMOTO wrote:

> >         http://www.netbsd.org/~ad/2020/rwlock.diff
> 
> 
> i guess in rw_downgrade
> newown = (owner & RW_NODEBUG) | RW_SPIN;
> 
> should be
> newown = (owner & (RW_NODEBUG | RW_SPIN));
> 
> as the owner might have failed to record the lock on acquisition.

Right.  I'll fix it and add a comment.  Good catch, thank you.

Andrew


Home | Main Index | Thread Index | Old Index