aboutsummaryrefslogtreecommitdiff
path: root/trace/control.h
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2016-01-07 16:55:26 +0300
committerStefan Hajnoczi <stefanha@redhat.com>2016-02-03 09:19:09 +0000
commit10578a257d94fb59449d0b0e441990c45a036ccc (patch)
tree5fc5b4d0935e70c3c2c784bc7dec0694e12e0b23 /trace/control.h
parentf246b86672118e4f0d0782f4c240d3666aa36710 (diff)
trace: add "-trace enable=..."
Allow enabling events without going through a file, for example: qemu-system-x86_64 -trace bdrv_aio_writev -trace bdrv_aio_readv or with globbing too: qemu-system-x86_64 -trace 'bdrv_aio_*' if an appropriate backend is enabled (simple, stderr, ftrace). Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Denis V. Lunev <den@openvz.org> Acked-by: Christian Borntraeger <borntraeger@de.ibm.com> Message-id: 1452174932-28657-6-git-send-email-den@openvz.org Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'trace/control.h')
-rw-r--r--trace/control.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/trace/control.h b/trace/control.h
index d50f3996c7..d5081ce169 100644
--- a/trace/control.h
+++ b/trace/control.h
@@ -181,6 +181,15 @@ void trace_init_events(const char *file);
*/
void trace_init_file(const char *file);
+/**
+ * trace_enable_events:
+ * @line_buf: A string with a glob pattern of events to be enabled or,
+ * if the string starts with '-', disabled.
+ *
+ * Enable or disable matching events.
+ */
+void trace_enable_events(const char *line_buf);
+
#include "trace/control-internal.h"