X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=include%2Flttng%2Flttng.h;h=8bdfe121c44bdce2acac16e3b5699e4848310cbf;hp=a137a4385218c91f176c14f1dc83e06b66390119;hb=d78d661021eb1c5761c631dbd525697769fe638b;hpb=90192ee7cea425e30bd065576612156dd6cf5608 diff --git a/include/lttng/lttng.h b/include/lttng/lttng.h index a137a4385..8bdfe121c 100644 --- a/include/lttng/lttng.h +++ b/include/lttng/lttng.h @@ -52,9 +52,16 @@ enum lttng_domain_type { LTTNG_DOMAIN_KERNEL = 1, LTTNG_DOMAIN_UST = 2, + + /* + * For now, the domains below are not implemented. However, we keep them + * here in order to retain their enum values for future development. Note + * that it is on the roadmap to implement them. + * LTTNG_DOMAIN_UST_EXEC_NAME = 3, LTTNG_DOMAIN_UST_PID = 4, LTTNG_DOMAIN_UST_PID_FOLLOW_CHILDREN = 5, + */ }; /* @@ -75,26 +82,26 @@ enum lttng_event_type { * LTTng consumer mode */ enum lttng_event_output { - LTTNG_EVENT_SPLICE = 0, - LTTNG_EVENT_MMAP = 1, + LTTNG_EVENT_SPLICE = 0, + LTTNG_EVENT_MMAP = 1, }; /* Event context possible type */ enum lttng_event_context_type { - LTTNG_EVENT_CONTEXT_PID = 0, - LTTNG_EVENT_CONTEXT_PERF_COUNTER = 1, - LTTNG_EVENT_CONTEXT_COMM = 2, - LTTNG_EVENT_CONTEXT_PRIO = 3, - LTTNG_EVENT_CONTEXT_NICE = 4, - LTTNG_EVENT_CONTEXT_VPID = 5, - LTTNG_EVENT_CONTEXT_TID = 6, - LTTNG_EVENT_CONTEXT_VTID = 7, - LTTNG_EVENT_CONTEXT_PPID = 8, - LTTNG_EVENT_CONTEXT_VPPID = 9, + LTTNG_EVENT_CONTEXT_PID = 0, + LTTNG_EVENT_CONTEXT_PERF_COUNTER = 1, + LTTNG_EVENT_CONTEXT_COMM = 2, + LTTNG_EVENT_CONTEXT_PRIO = 3, + LTTNG_EVENT_CONTEXT_NICE = 4, + LTTNG_EVENT_CONTEXT_VPID = 5, + LTTNG_EVENT_CONTEXT_TID = 6, + LTTNG_EVENT_CONTEXT_VTID = 7, + LTTNG_EVENT_CONTEXT_PPID = 8, + LTTNG_EVENT_CONTEXT_VPPID = 9, }; enum lttng_calibrate_type { - LTTNG_CALIBRATE_FUNCTION = 0, + LTTNG_CALIBRATE_FUNCTION = 0, }; struct lttng_domain { @@ -172,7 +179,7 @@ struct lttng_channel_attr { * Channel information structure. For both kernel and user-space. */ struct lttng_channel { - char name[NAME_MAX]; + char name[LTTNG_SYMBOL_NAME_LEN]; uint32_t enabled; struct lttng_channel_attr attr; }; @@ -242,7 +249,7 @@ extern int lttng_create_session(const char *name, const char *path); * The session will not be useable anymore, tracing will stopped for all * registered trace and tracing buffers will be flushed. */ -extern int lttng_destroy_session(struct lttng_handle *handle); +extern int lttng_destroy_session(const char *name); /* * List all tracing sessions. @@ -256,7 +263,7 @@ extern int lttng_list_sessions(struct lttng_session **sessions); * * Return the size of the "lttng_domain" array. Caller must free(3). */ -extern int lttng_list_domains(struct lttng_handle *handle, +extern int lttng_list_domains(const char *session_name, struct lttng_domain **domains); /* @@ -314,12 +321,12 @@ extern int lttng_register_consumer(struct lttng_handle *handle, /* * Start tracing for *all* registered trace (kernel and user-space). */ -extern int lttng_start_tracing(struct lttng_handle *handle); +extern int lttng_start_tracing(const char *session_name); /* * Stop tracing for *all* registered trace (kernel and user-space). */ -extern int lttng_stop_tracing(struct lttng_handle *handle); +extern int lttng_stop_tracing(const char *session_name); /* * Add context to event for a specific channel.