X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=liblttsessiondcomm%2Fliblttsessiondcomm.h;h=a06bb91757405fe4ad3a3ff56a36613f840577fe;hp=a2185f911559b2a24801780ba88efaed38a32fce;hb=7d8234d9e6f162ee642cdbec911f46c29b012c3d;hpb=d65106b1011efccf8fa5f9d7c8f2dfb0de38f5e8 diff --git a/liblttsessiondcomm/liblttsessiondcomm.h b/liblttsessiondcomm/liblttsessiondcomm.h index a2185f911..a06bb9175 100644 --- a/liblttsessiondcomm/liblttsessiondcomm.h +++ b/liblttsessiondcomm/liblttsessiondcomm.h @@ -4,8 +4,8 @@ * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. + * as published by the Free Software Foundation; only version 2 + * of the License. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -41,25 +41,25 @@ #define LTTCOMM_ERR_INDEX(code) (code - LTTCOMM_OK) enum lttcomm_sessiond_command { - /* Tracer context command */ - LTTNG_KERNEL_ADD_CONTEXT, - LTTNG_KERNEL_CREATE_CHANNEL, - LTTNG_KERNEL_DISABLE_CHANNEL, - LTTNG_KERNEL_DISABLE_EVENT, - LTTNG_KERNEL_DISABLE_ALL_EVENT, - LTTNG_KERNEL_ENABLE_CHANNEL, - LTTNG_KERNEL_ENABLE_EVENT, - LTTNG_KERNEL_ENABLE_ALL_EVENT, - LTTNG_KERNEL_LIST_EVENTS, - /* Session daemon context command */ + /* Tracer command */ + LTTNG_ADD_CONTEXT, + LTTNG_DISABLE_CHANNEL, + LTTNG_DISABLE_EVENT, + LTTNG_DISABLE_ALL_EVENT, + LTTNG_ENABLE_CHANNEL, + LTTNG_ENABLE_EVENT, + LTTNG_ENABLE_ALL_EVENT, + /* Session daemon command */ LTTNG_CREATE_SESSION, LTTNG_DESTROY_SESSION, - LTTNG_LIST_SESSIONS, - LTTNG_LIST_TRACES, + LTTNG_LIST_CHANNELS, + LTTNG_LIST_DOMAINS, LTTNG_LIST_EVENTS, - LTTNG_LIST_TRACEABLE_APPS, + LTTNG_LIST_SESSIONS, + LTTNG_LIST_TRACEPOINTS, LTTNG_START_TRACE, LTTNG_STOP_TRACE, + LTTNG_CALIBRATE, }; /* @@ -69,6 +69,8 @@ enum lttcomm_return_code { LTTCOMM_OK = 1000, /* Ok */ LTTCOMM_ERR, /* Unknown Error */ LTTCOMM_UND, /* Undefine command */ + LTTCOMM_NOT_IMPLEMENTED, /* Command not implemented */ + LTTCOMM_UNKNOWN_DOMAIN, /* Tracing domain not known */ LTTCOMM_ALLOC_FAIL, /* Trace allocation fail */ LTTCOMM_NO_SESSION, /* No session found */ LTTCOMM_CREATE_FAIL, /* Create trace fail */ @@ -85,6 +87,7 @@ enum lttcomm_return_code { LTTCOMM_EXIST_SESS, /* Session name already exist */ LTTCOMM_NO_EVENT, /* No event found */ LTTCOMM_KERN_NA, /* Kernel tracer unavalable */ + LTTCOMM_KERN_EVENT_EXIST, /* Kernel event already exists */ LTTCOMM_KERN_SESS_FAIL, /* Kernel create session failed */ LTTCOMM_KERN_CHAN_FAIL, /* Kernel create channel failed */ LTTCOMM_KERN_CHAN_NOT_FOUND, /* Kernel channel not found */ @@ -124,9 +127,8 @@ enum lttcomm_return_code { */ struct lttcomm_session_msg { u32 cmd_type; /* enum lttcomm_sessiond_command */ - char session_name[NAME_MAX]; - char path[PATH_MAX]; - pid_t pid; + struct lttng_session session; + struct lttng_domain domain; union { struct { char channel_name[NAME_MAX]; @@ -145,8 +147,13 @@ struct lttcomm_session_msg { struct { char channel_name[NAME_MAX]; char event_name[NAME_MAX]; - struct lttng_kernel_context ctx; + struct lttng_event_context ctx; } context; + /* List */ + struct { + char channel_name[NAME_MAX]; + } list; + struct lttng_calibrate calibrate; } u; };