From c141c242ac0a55a34b58cf2b06d13964d00507a4 Mon Sep 17 00:00:00 2001 From: John Baldwin Date: Tue, 4 Mar 2003 22:34:07 +0000 Subject: [PATCH] Bah, fix a bogon in the last commit: get the sense of a compare test right so that we allow a sleepable lock to be acquired with Giant held rather than allowing a sleepable lock to be acquired with anything but Giant held. --- sys/kern/subr_witness.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/kern/subr_witness.c b/sys/kern/subr_witness.c index f12ff8201f3..d4315de450d 100644 --- a/sys/kern/subr_witness.c +++ b/sys/kern/subr_witness.c @@ -675,7 +675,7 @@ witness_lock(struct lock_object *lock, int flags, const char *file, int line) * is Giant, then skip it. */ if ((lock->lo_flags & LO_SLEEPABLE) != 0 && - lock1->li_lock != &Giant.mtx_object) + lock1->li_lock == &Giant.mtx_object) continue; /* * If we are locking a sleepable lock and this lock