From 97e378fb00972dd4d5c50c5d134cfaac0a90728b Mon Sep 17 00:00:00 2001 From: jhb Date: Wed, 30 Jul 2003 20:42:15 +0000 Subject: When complaining about a sleeping thread owning a mutex, display the thread's pid to make debugging easier for people who don't want to have to use the intended tool for these panics (witness). Indirectly prodded by: kris --- sys/kern/kern_mutex.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'sys/kern/kern_mutex.c') diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c index 18dcc7e..bf157eb 100644 --- a/sys/kern/kern_mutex.c +++ b/sys/kern/kern_mutex.c @@ -119,7 +119,9 @@ propagate_priority(struct thread *td) MPASS(td->td_proc != NULL); MPASS(td->td_proc->p_magic == P_MAGIC); - KASSERT(!TD_IS_SLEEPING(td), ("sleeping thread owns a mutex")); + KASSERT(!TD_IS_SLEEPING(td), ( + "sleeping thread (pid %d) owns a mutex", + td->td_proc->p_pid)); if (td->td_priority <= pri) /* lower is higher priority */ return; -- cgit v1.1