From 42cfa2cc9eb59ddbe448a8b539720b20fb70fad9 Mon Sep 17 00:00:00 2001 From: jhb Date: Fri, 6 Jan 2006 18:02:12 +0000 Subject: Fix various places that were testing td_critnest to see if interrupts should remain disabled during a trap or not to check td_md.md_spinlock_count instead. --- sys/amd64/amd64/trap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sys/amd64') diff --git a/sys/amd64/amd64/trap.c b/sys/amd64/amd64/trap.c index 3ed7572..acd6140 100644 --- a/sys/amd64/amd64/trap.c +++ b/sys/amd64/amd64/trap.c @@ -220,10 +220,10 @@ trap(frame) printf("kernel trap %d with interrupts disabled\n", type); /* - * We shouldn't enable interrupts while in a critical - * section or servicing an NMI. + * We shouldn't enable interrupts while holding a + * spin lock or servicing an NMI. */ - if (type != T_NMI && td->td_critnest == 0) + if (type != T_NMI && td->td_md.md_spinlock_count == 0) enable_intr(); } } -- cgit v1.1