diff options
author | Jonathan Haslam <Jonathan.Haslam@Sun.COM> | 2009-02-13 07:13:13 +0000 |
---|---|---|
committer | Jonathan Haslam <Jonathan.Haslam@Sun.COM> | 2009-02-13 07:13:13 +0000 |
commit | b9e93c10c0a2a4bb069d38bb311021a9478c4711 (patch) | |
tree | 8a82dbbc533447409d902987f543b2ad72e8e78a /usr/src/uts/common/xen/dtrace/xdt.c | |
parent | 2e5e9e19867a0d75685f5beb2fe1b0e31491d49b (diff) | |
download | illumos-gate-b9e93c10c0a2a4bb069d38bb311021a9478c4711.tar.gz |
PSARC 2008/480 DTrace CPC Provider
6486156 DTrace cpc provider
Diffstat (limited to 'usr/src/uts/common/xen/dtrace/xdt.c')
-rw-r--r-- | usr/src/uts/common/xen/dtrace/xdt.c | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/usr/src/uts/common/xen/dtrace/xdt.c b/usr/src/uts/common/xen/dtrace/xdt.c index bac7f100e9..85c876b479 100644 --- a/usr/src/uts/common/xen/dtrace/xdt.c +++ b/usr/src/uts/common/xen/dtrace/xdt.c @@ -20,7 +20,7 @@ */ /* - * Copyright 2008 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ @@ -782,7 +782,7 @@ xdt_set_trace_mask(uint32_t mask) } /*ARGSUSED*/ -static void +static int xdt_enable(void *arg, dtrace_id_t id, void *parg) { xdt_probe_t *p = parg; @@ -801,22 +801,15 @@ xdt_enable(void *arg, dtrace_id_t id, void *parg) } if (xdt_cyclic == CYCLIC_NONE) { - /* - * DTrace doesn't have the notion of failing an enabling. It - * works on the premise that, if you have advertised a probe - * via the pops->dtps_provide() function, you can enable it. - * Failure is not an option. In the case where we can't enable - * Xen tracing the consumer will carry on regardless and - * think all is OK except the probes will never fire. - */ tbuf_op.cmd = XEN_SYSCTL_TBUFOP_enable; if (xdt_sysctl_tbuf(&tbuf_op) != 0) { cmn_err(CE_NOTE, "Couldn't enable hypervisor tracing."); - return; + return (-1); } xdt_cyclic_enable(); } + return (0); } /*ARGSUSED*/ |