diff options
author | dwhite <dwhite@FreeBSD.org> | 2005-04-30 20:01:00 +0000 |
---|---|---|
committer | dwhite <dwhite@FreeBSD.org> | 2005-04-30 20:01:00 +0000 |
commit | c8fa8099674d921d50dae72e3a58ef66ac9c7fbc (patch) | |
tree | b1d1d16a2806520655c3bf213640cc3b5593de38 /sys/sys/smp.h | |
parent | ebe4b8304d164a842cc96bcc863c9321a37f57ff (diff) | |
download | FreeBSD-src-c8fa8099674d921d50dae72e3a58ef66ac9c7fbc.zip FreeBSD-src-c8fa8099674d921d50dae72e3a58ef66ac9c7fbc.tar.gz |
Implement an alternate method to stop CPUs when entering DDB. Normally we use
a regular IPI vector, but this vector is blocked when interrupts are disabled.
With "options KDB_STOP_NMI" and debug.kdb.stop_cpus_with_nmi set, KDB will
send an NMI to each CPU instead. The code also has a context-stuffing
feature which helps ddb extract the state of processes running on the
stopped CPUs.
KDB_STOP_NMI is only useful with SMP and complains if SMP is not defined.
This feature only applies to i386 and amd64 at the moment, but could be
used on other architectures with the appropriate MD bits.
Submitted by: ups
Diffstat (limited to 'sys/sys/smp.h')
-rw-r--r-- | sys/sys/smp.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/sys/smp.h b/sys/sys/smp.h index 88353fc..88c6ae2 100644 --- a/sys/sys/smp.h +++ b/sys/sys/smp.h @@ -101,6 +101,10 @@ int restart_cpus(cpumask_t); int stop_cpus(cpumask_t); void smp_rendezvous_action(void); extern struct mtx smp_ipi_mtx; + +#ifdef KDB_STOP_NMI +int stop_cpus_nmi(cpumask_t); +#endif #endif /* SMP */ void smp_rendezvous(void (*)(void *), void (*)(void *), |