- Assert that witness_cold is not true in enroll().
- Only check witness_watch once in enroll(). Reported by: ru (2)
This commit is contained in:
parent
526f81a883
commit
9c9c52a3ed
@ -1180,7 +1180,8 @@ enroll(const char *description, struct lock_class *lock_class)
|
||||
{
|
||||
struct witness *w;
|
||||
|
||||
if (!witness_watch || witness_watch == 0 || panicstr != NULL)
|
||||
KASSERT(!witness_cold, ("enroll called too early"));
|
||||
if (witness_watch == 0 || panicstr != NULL)
|
||||
return (NULL);
|
||||
if ((lock_class->lc_flags & LC_SPINLOCK) && witness_skipspin)
|
||||
return (NULL);
|
||||
|
Loading…
Reference in New Issue
Block a user