2 * Copyright (C) 2011 - David Goulet <david.goulet@polymtl.ca>
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version 2
7 * of the License, or (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
22 #include "ltt-sessiond.h"
24 #include "lttng-kernel.h"
26 /* Kernel event list */
27 struct ltt_kernel_event_list
{
28 struct cds_list_head head
;
31 /* Channel stream list */
32 struct ltt_kernel_stream_list
{
33 struct cds_list_head head
;
37 struct ltt_kernel_channel_list
{
38 struct cds_list_head head
;
42 struct ltt_kernel_event
{
44 struct lttng_kernel_event
*event
;
45 struct cds_list_head list
;
49 struct ltt_kernel_channel
{
52 unsigned int stream_count
;
53 struct lttng_kernel_channel
*channel
;
54 struct ltt_kernel_event_list events_list
;
55 struct ltt_kernel_stream_list stream_list
;
56 struct cds_list_head list
;
60 struct ltt_kernel_metadata
{
63 struct lttng_kernel_channel
*conf
;
67 struct ltt_kernel_stream
{
71 struct cds_list_head list
;
75 struct ltt_kernel_session
{
77 int metadata_stream_fd
;
78 unsigned int channel_count
;
79 unsigned int stream_count_global
;
80 struct ltt_kernel_metadata
*metadata
;
81 struct ltt_kernel_channel_list channel_list
;
84 /* UST trace representation */
85 struct ltt_ust_trace
{
86 struct cds_list_head list
;
90 struct cds_list_head markers
;
93 struct ltt_ust_marker
{
94 struct cds_list_head list
;
99 int get_trace_count_per_session(struct ltt_session
*session
);
100 void get_traces_per_session(struct ltt_session
*session
, struct lttng_trace
*traces
);
101 int ust_create_trace(struct command_ctx
*cmd_ctx
);
102 int ust_start_trace(struct command_ctx
*cmd_ctx
);
103 int ust_stop_trace(struct command_ctx
*cmd_ctx
);
105 #endif /* _LTT_TRACE_H */