From 3b783acd2aff20e985ce27e6a775682b0694be43 Mon Sep 17 00:00:00 2001 From: John Baldwin Date: Sat, 7 Jan 2006 14:03:15 +0000 Subject: [PATCH] Revert an untested local change that crept in with the lo_class changes and subsequently broke the build. This change is supposed to fix the case where doing a mtx_destroy() off a spin mutex while you hold it fails. If it had been tested I would just leave it in, but it hasn't been tested yet, so it will have to wait until later. --- sys/kern/kern_mutex.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c index f06813a3321d..81addbe1a640 100644 --- a/sys/kern/kern_mutex.c +++ b/sys/kern/kern_mutex.c @@ -883,10 +883,6 @@ mtx_destroy(struct mtx *m) else { MPASS((m->mtx_lock & (MTX_RECURSED|MTX_CONTESTED)) == 0); - /* Perform the non-mtx related part of mtx_unlock_spin(). */ - if (LO_CLASSINDEX(&m->mtx_object) == LOCK_CLASS_SPIN_MUTEX) - spinlock_exit(); - /* Tell witness this isn't locked to make it happy. */ WITNESS_UNLOCK(&m->mtx_object, LOP_EXCLUSIVE, __FILE__, __LINE__);