HomeFreeBSD

witness: sleepable rm locks are not sleepable in read mode

Description

witness: sleepable rm locks are not sleepable in read mode

There are two classes of rm lock, one "sleepable" and one not. But even
a "sleepable" rm lock is only sleepable in write mode, and is
non-sleepable when taken in read mode.

Warn about sleepable rm locks in read mode as non-sleepable locks. Do
this by defining a new lock operation flag, LOP_NOSLEEP, to indicate
that a lock is non-sleepable despite what the LO_SLEEPABLE flag would
indicate, and defining a new witness lock instance flag, LI_SLEEPABLE,
to track the product of LO_SLEEPABLE and LOP_NOSLEEP on the lock
instance.

Reviewed by: markj
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D22527

Details

Provenance
rlibbyAuthored on
Reviewer
markj
Differential Revision
D22527: witness: sleepable rm locks are not sleepable in read mode
Parents
rS355125: cache: stop reusing .. entries on enter
Branches
Unknown
Tags
Unknown