diff options
author | markj <markj@FreeBSD.org> | 2014-07-14 04:38:17 +0000 |
---|---|---|
committer | markj <markj@FreeBSD.org> | 2014-07-14 04:38:17 +0000 |
commit | 880dd1a983b61825a671f8a16103eb480f6ce342 (patch) | |
tree | f6f00a8ecef69c372df2dbabbd94de9a70811897 /sys/sys/dtrace_bsd.h | |
parent | 0b964c341a8548648d88f3097969b1e9b707da2e (diff) | |
download | FreeBSD-src-880dd1a983b61825a671f8a16103eb480f6ce342.zip FreeBSD-src-880dd1a983b61825a671f8a16103eb480f6ce342.tar.gz |
Invoke the DTrace trap handler before calling trap() on amd64. This matches
the upstream implementation and helps ensure that a trap induced by tracing
fbt::trap:entry is handled without recursively generating another trap.
This makes it possible to run most (but not all) of the DTrace tests under
common/safety/ without triggering a kernel panic.
Submitted by: Anton Rang <anton.rang@isilon.com> (original version)
Phabric: D95
Diffstat (limited to 'sys/sys/dtrace_bsd.h')
-rw-r--r-- | sys/sys/dtrace_bsd.h | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/sys/sys/dtrace_bsd.h b/sys/sys/dtrace_bsd.h index 6dd9024..b451022 100644 --- a/sys/sys/dtrace_bsd.h +++ b/sys/sys/dtrace_bsd.h @@ -48,15 +48,14 @@ extern cyclic_clock_func_t cyclic_clock_func; void clocksource_cyc_set(const struct bintime *t); +int dtrace_trap(struct trapframe *); + /* * The dtrace module handles traps that occur during a DTrace probe. * This type definition is used in the trap handler to provide a - * hook for the dtrace module to register it's handler with. + * hook for the dtrace module to register its handler with. */ -typedef int (*dtrace_trap_func_t)(struct trapframe *, u_int); - -int dtrace_trap(struct trapframe *, u_int); - +typedef int (*dtrace_trap_func_t)(struct trapframe *); extern dtrace_trap_func_t dtrace_trap_func; /* |