summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_clock.c
diff options
context:
space:
mode:
authoremaste <emaste@FreeBSD.org>2007-05-28 21:50:54 +0000
committeremaste <emaste@FreeBSD.org>2007-05-28 21:50:54 +0000
commit8fbe911ae9bad94ad139c5ff6eba805ad2e22fe4 (patch)
treea3598a160d9facc30bcea9b29a1ad32091a655a5 /sys/kern/kern_clock.c
parent1dfb7ec904da0a70b075bcc0c871dc472cbb3dc0 (diff)
downloadFreeBSD-src-8fbe911ae9bad94ad139c5ff6eba805ad2e22fe4.zip
FreeBSD-src-8fbe911ae9bad94ad139c5ff6eba805ad2e22fe4.tar.gz
Revert 1.197 and instead avoid calling kdb_enter() if the KDB_UNATTENDED
option is in use.
Diffstat (limited to 'sys/kern/kern_clock.c')
-rw-r--r--sys/kern/kern_clock.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/sys/kern/kern_clock.c b/sys/kern/kern_clock.c
index aa5839b..ac404dc 100644
--- a/sys/kern/kern_clock.c
+++ b/sys/kern/kern_clock.c
@@ -37,6 +37,7 @@
#include <sys/cdefs.h>
__FBSDID("$FreeBSD$");
+#include "opt_kdb.h"
#include "opt_device_polling.h"
#include "opt_hwpmc_hooks.h"
#include "opt_ntp.h"
@@ -555,7 +556,7 @@ watchdog_config(void *unused __unused, u_int cmd, int *error)
/*
* Handle a watchdog timeout by dumping interrupt information and
- * then panicking.
+ * then either dropping to DDB or panicking.
*/
static void
watchdog_fire(void)
@@ -578,7 +579,13 @@ watchdog_fire(void)
inttotal += *curintr++;
}
printf("Total %20ju\n", (uintmax_t)inttotal);
+
+#if defined(KDB) && !defined(KDB_UNATTENDED)
+ kdb_backtrace();
+ kdb_enter("watchdog timeout");
+#else
panic("watchdog timeout");
+#endif
}
#endif /* SW_WATCHDOG */
OpenPOWER on IntegriCloud