Page MenuHomeFreeBSD

D40283.id122470.diff
No OneTemporary

D40283.id122470.diff

diff --git a/sys/cddl/dev/kinst/amd64/kinst_isa.c b/sys/cddl/dev/kinst/amd64/kinst_isa.c
--- a/sys/cddl/dev/kinst/amd64/kinst_isa.c
+++ b/sys/cddl/dev/kinst/amd64/kinst_isa.c
@@ -496,7 +496,8 @@
dtrace_kinst_probedesc_t *pd;
const char *func;
int error, instrsize, n, off;
- uint8_t *instr, *limit;
+ uint8_t *instr, *limit, *tmp;
+ bool found;
pd = opaque;
func = symval->name;
@@ -512,11 +513,17 @@
/*
* Ignore functions not beginning with the usual function prologue.
- * These might correspond to exception handlers with which we should not
- * meddle. This does however exclude functions which can be safely
- * traced, such as cpu_switch().
+ * These might correspond to exception handlers with which we should
+ * not meddle.
*/
- if (*instr != KINST_PUSHL_RBP)
+ tmp = instr;
+ found = false;
+ while (tmp < limit) {
+ if (*tmp == KINST_PUSHL_RBP)
+ found = true;
+ tmp += dtrace_instr_size(tmp);
+ }
+ if (!found)
return (0);
n = 0;

File Metadata

Mime Type
text/plain
Expires
Wed, Apr 1, 7:36 AM (20 h, 40 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
30670691
Default Alt Text
D40283.id122470.diff (982 B)

Event Timeline