X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=ltt-sessiond%2Ftrace.h;h=5b4ff68ff3a0c2718d90c5f5c8f377551e81e052;hb=6aea26bc854e8090e609502e53a3e2923cb3b2c5;hp=9cbdaffd1dbb1da13f02d3ff80e6444b6b98df95;hpb=fda89c9b0a068c6d528e1ef9095476118708c181;p=lttng-tools.git diff --git a/ltt-sessiond/trace.h b/ltt-sessiond/trace.h index 9cbdaffd1..5b4ff68ff 100644 --- a/ltt-sessiond/trace.h +++ b/ltt-sessiond/trace.h @@ -19,16 +19,39 @@ #ifndef _LTT_TRACE_H #define _LTT_TRACE_H -/* LTTng trace representation */ -struct ltt_lttng_trace { +#include "ltt-sessiond.h" +#include "session.h" +#include "lttng-kernel.h" + +/* Kernel event list */ +struct ltt_kernel_event_list { + struct cds_list_head head; +}; + +/* Kernel event */ +struct ltt_kernel_event { + int fd; + struct lttng_kernel_event *event; struct cds_list_head list; - char trace_name[NAME_MAX]; - struct cds_list_head marker_list; +}; + +/* Kernel channel */ +struct ltt_kernel_channel { + int fd; + struct lttng_kernel_channel *channel; + struct ltt_kernel_event_list events_list; +}; + +/* Kernel session */ +struct ltt_kernel_session { + int fd; + struct ltt_kernel_channel *channel; }; /* UST trace representation */ struct ltt_ust_trace { struct cds_list_head list; + char name[NAME_MAX]; int shmid; pid_t pid; struct cds_list_head markers; @@ -40,4 +63,10 @@ struct ltt_ust_marker { char *channel; }; +int get_trace_count_per_session(struct ltt_session *session); +void get_traces_per_session(struct ltt_session *session, struct lttng_trace *traces); +int ust_create_trace(struct command_ctx *cmd_ctx); +int ust_start_trace(struct command_ctx *cmd_ctx); +int ust_stop_trace(struct command_ctx *cmd_ctx); + #endif /* _LTT_TRACE_H */