Lines Matching refs:debug

76 #include <kern/debug.h>
430 * a usimple_lock is setting it up for debug checking.
437 ((l)->debug.state & USLOCK_CHECKED))
457 l->debug.state = uslock_check ? USLOCK_INITIALIZED : 0;
458 l->debug.lock_cpu = l->debug.unlock_cpu = 0;
459 l->debug.lock_pc = l->debug.unlock_pc = INVALID_PC;
460 l->debug.lock_thread = l->debug.unlock_thread = INVALID_THREAD;
461 l->debug.duration[0] = l->debug.duration[1] = 0;
462 l->debug.unlock_cpu = l->debug.unlock_cpu = 0;
463 l->debug.unlock_pc = l->debug.unlock_pc = INVALID_PC;
464 l->debug.unlock_thread = l->debug.unlock_thread = INVALID_THREAD;
481 if (!(l->debug.state & USLOCK_INIT))
482 panic("%s: %p is not an initialized lock, 0x%x", caller, l, l->debug.state);
511 if ((l->debug.state & USLOCK_TAKEN) && l->debug.lock_thread &&
512 l->debug.lock_thread == (void *) current_thread()) {
514 caller, l, l->debug.lock_pc);
516 l->debug.lock_thread, pc);
543 if (!((l->debug.state & ~USLOCK_TAKEN) == USLOCK_INITIALIZED))
546 if ((l->debug.state & USLOCK_TAKEN))
551 l->debug.lock_thread = (void *)current_thread();
552 l->debug.state |= USLOCK_TAKEN;
553 l->debug.lock_pc = pc;
554 l->debug.lock_cpu = mycpu;
582 if (!(l->debug.state & USLOCK_TAKEN))
585 if (l->debug.lock_thread != (void *) current_thread())
587 caller, l, l->debug.lock_thread);
588 if (l->debug.lock_cpu != mycpu) {
591 printf(" (acquired on cpu 0x%x)\n", l->debug.lock_cpu);
596 l->debug.unlock_thread = l->debug.lock_thread;
597 l->debug.lock_thread = INVALID_PC;
598 l->debug.state &= ~USLOCK_TAKEN;
599 l->debug.unlock_pc = pc;
600 l->debug.unlock_cpu = mycpu;
644 if (!((l->debug.state & ~USLOCK_TAKEN) == USLOCK_INITIALIZED))
647 if ((l->debug.state & USLOCK_TAKEN))
652 l->debug.lock_thread = (void *) current_thread();
653 l->debug.state |= USLOCK_TAKEN;
654 l->debug.lock_pc = pc;
655 l->debug.lock_cpu = mycpu;
1985 * penalize only lock groups that have debug/stats enabled