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.
19 #ifndef _LIBLTTNGCTL_H
20 #define _LIBLTTNGCTL_H
24 #include <uuid/uuid.h>
26 /* Default unix group name for tracing.
28 #define DEFAULT_TRACING_GROUP "tracing"
30 /* Environment variable to set session daemon
33 #define LTTNG_SESSIOND_PATH_ENV "LTTNG_SESSIOND_PATH"
35 /* UUID string length (including \0) */
36 #define UUID_STR_LEN 37
37 /* UUID short string version length (including \0) */
38 #define UUID_SHORT_STR_LEN 9
42 /* Trace type for lttng_trace.
44 enum lttng_trace_type
{
48 /* Simple structure representing a session.
50 struct lttng_session
{
55 /* Simple trace representation.
60 enum lttng_trace_type type
;
64 * LTTng DebugFS ABI structures.
66 enum lttng_instrum_type
{
70 struct lttng_channel
{
71 int overwrite
; /* 1: overwrite, 0: discard */
74 unsigned int switch_timer_interval
;
75 unsigned int read_timer_interval
;
79 enum lttng_instrum_type itype
;
83 extern int lttng_create_session(char *name
, uuid_t
*session_id
);
84 extern int lttng_destroy_session(uuid_t
*uuid
);
85 extern int lttng_connect_sessiond(void);
86 extern int lttng_disconnect_sessiond(void);
87 extern int lttng_set_tracing_group(const char *name
);
88 extern int lttng_check_session_daemon(void);
89 extern const char *lttng_get_readable_code(int code
);
90 extern int lttng_ust_list_apps(pid_t
**pids
);
91 extern int lttng_list_sessions(struct lttng_session
**sessions
);
92 extern int lttng_list_traces(uuid_t
*uuid
, struct lttng_trace
**traces
);
93 extern void lttng_set_current_session_uuid(uuid_t
*uuid
);
94 extern int lttng_ust_create_trace(pid_t pid
);
95 extern int lttng_ust_start_trace(pid_t pid
);
96 extern int lttng_ust_stop_trace(pid_t pid
);
98 #endif /* _LIBLTTNGCTL_H */
This page took 0.033255 seconds and 5 git commands to generate.