From 5fe0ebe46ad322af1c7456f1df436a2a6cc278a0 Mon Sep 17 00:00:00 2001 From: ivoras Date: Mon, 5 Mar 2012 14:19:43 +0000 Subject: Print out process name and thread id in the debugging message. This is useful because the message can end up in system logs in non-debugging operation. Reviewed by: attilio (earlier version) --- sys/kern/kern_lock.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'sys/kern') diff --git a/sys/kern/kern_lock.c b/sys/kern/kern_lock.c index 614beb2..00f1b11 100644 --- a/sys/kern/kern_lock.c +++ b/sys/kern/kern_lock.c @@ -1277,8 +1277,9 @@ lockmgr_printinfo(const struct lock *lk) (uintmax_t)LK_SHARERS(lk->lk_lock)); else { td = lockmgr_xholder(lk); - printf("lock type %s: EXCL by thread %p (pid %d)\n", - lk->lock_object.lo_name, td, td->td_proc->p_pid); + printf("lock type %s: EXCL by thread %p " + "(pid %d, %s, tid %d)\n", lk->lock_object.lo_name, td, + td->td_proc->p_pid, td->td_proc->p_comm, td->td_tid); } x = lk->lk_lock; -- cgit v1.1