Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F150336349
D40283.id122470.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
982 B
Referenced Files
None
Subscribers
None
D40283.id122470.diff
View Options
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
Details
Attached
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)
Attached To
Mode
D40283: kinst: check for 'push %rbp' anywhere in the function
Attached
Detach File
Event Timeline
Log In to Comment