summaryrefslogtreecommitdiffstats
path: root/sys/cddl
diff options
context:
space:
mode:
authorrstone <rstone@FreeBSD.org>2011-11-11 03:49:42 +0000
committerrstone <rstone@FreeBSD.org>2011-11-11 03:49:42 +0000
commitf6710005c7b5cbaa57962878278d7b6ee1bd22e2 (patch)
treeadc6573d0b6fbc3271e9159bd4a895d56ccd401c /sys/cddl
parent85b2830346b20c323d2332a339c06ffca315b1b0 (diff)
downloadFreeBSD-src-f6710005c7b5cbaa57962878278d7b6ee1bd22e2.zip
FreeBSD-src-f6710005c7b5cbaa57962878278d7b6ee1bd22e2.tar.gz
Correct the types of the arguments to return probes of the syscall
provider. Previously we were erroneously supplying the argument types of the corresponding entry probe. Reviewed by: rpaulo MFC after: 1 week
Diffstat (limited to 'sys/cddl')
-rw-r--r--sys/cddl/dev/systrace/systrace.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/cddl/dev/systrace/systrace.c b/sys/cddl/dev/systrace/systrace.c
index cc48747..ff63129 100644
--- a/sys/cddl/dev/systrace/systrace.c
+++ b/sys/cddl/dev/systrace/systrace.c
@@ -213,6 +213,7 @@ systrace_probe(u_int32_t id, int sysnum, struct sysent *sysent, void *params,
/* Process the probe using the converted argments. */
dtrace_probe(id, uargs[0], uargs[1], uargs[2], uargs[3], uargs[4]);
}
+
#endif
static void
@@ -220,8 +221,12 @@ systrace_getargdesc(void *arg, dtrace_id_t id, void *parg, dtrace_argdesc_t *des
{
int sysnum = SYSTRACE_SYSNUM((uintptr_t)parg);
- systrace_setargdesc(sysnum, desc->dtargd_ndx, desc->dtargd_native,
- sizeof(desc->dtargd_native));
+ if (SYSTRACE_ISENTRY((uintptr_t)parg))
+ systrace_entry_setargdesc(sysnum, desc->dtargd_ndx,
+ desc->dtargd_native, sizeof(desc->dtargd_native));
+ else
+ systrace_return_setargdesc(sysnum, desc->dtargd_ndx,
+ desc->dtargd_native, sizeof(desc->dtargd_native));
if (desc->dtargd_native[0] == '\0')
desc->dtargd_ndx = DTRACE_ARGNONE;
OpenPOWER on IntegriCloud