Rename liblttsessiondcomm to liblttng-sessiond-comm, install it.
[lttng-tools.git] / include / lttng / lttng.h
index 2cbb7f7ed38ddcda2f5efb0ac926d89b9e1f9863..c08580ac2fc70d076e1ddedbd294a6751f10c76e 100644 (file)
  * Domain type are the different possible tracers.
  */
 enum lttng_domain_type {
-       LTTNG_DOMAIN_KERNEL,
-       LTTNG_DOMAIN_UST,
-       LTTNG_DOMAIN_UST_EXEC_NAME,
-       LTTNG_DOMAIN_UST_PID,
-       LTTNG_DOMAIN_UST_PID_FOLLOW_CHILDREN,
-};
-
-struct lttng_domain {
-       enum lttng_domain_type type;
-       union {
-               pid_t pid;
-               char exec_name[NAME_MAX];
-       } attr;
+       LTTNG_DOMAIN_KERNEL                   = 1,
+       LTTNG_DOMAIN_UST                      = 2,
+       LTTNG_DOMAIN_UST_EXEC_NAME            = 3,
+       LTTNG_DOMAIN_UST_PID                  = 4,
+       LTTNG_DOMAIN_UST_PID_FOLLOW_CHILDREN  = 5,
 };
 
 /*
@@ -98,6 +90,18 @@ enum lttng_event_context_type {
        LTTNG_EVENT_CONTEXT_VPPID              = 9,
 };
 
+enum lttng_calibrate_type {
+       LTTNG_CALIBRATE_FUNCTION               = 0,
+};
+
+struct lttng_domain {
+       enum lttng_domain_type type;
+       union {
+               pid_t pid;
+               char exec_name[NAME_MAX];
+       } attr;
+};
+
 /* Perf counter attributes */
 struct lttng_event_perf_counter_ctx {
        uint32_t type;
@@ -138,6 +142,7 @@ struct lttng_event_function_attr {
 struct lttng_event {
        char name[LTTNG_SYMBOL_NAME_LEN];
        enum lttng_event_type type;
+       uint32_t enabled;
        /* Per event type configuration */
        union {
                struct lttng_event_probe_attr probe;
@@ -162,9 +167,14 @@ struct lttng_channel_attr {
  */
 struct lttng_channel {
        char name[NAME_MAX];
+       uint32_t enabled;
        struct lttng_channel_attr attr;
 };
 
+struct lttng_calibrate {
+       enum lttng_calibrate_type type;
+};
+
 /*
  * Basic session information.
  *
@@ -209,13 +219,45 @@ extern int lttng_create_session(const char *name, const char *path);
 extern int lttng_destroy_session(const char *name);
 
 /*
- * List tracing sessions.
+ * List all tracing sessions.
  *
- * Return the size of the "lttng_session" array. Caller must free(3) the
- * returned data.
+ * Return the size of the "lttng_session" array. Caller must free(3).
  */
 extern int lttng_list_sessions(struct lttng_session **sessions);
 
+/*
+ * List registered domain(s) of a session.
+ *
+ * Return the size of the "lttng_domain" array. Caller must free(3).
+ */
+extern int lttng_list_domains(const char *session_name,
+               struct lttng_domain **domains);
+
+/*
+ * List channel(s) of a session.
+ *
+ * Return the size of the "lttng_channel" array. Caller must free(3).
+ */
+extern int lttng_list_channels(struct lttng_domain *domain,
+               const char *session_name, struct lttng_channel **channels);
+
+/*
+ * List event(s) of a session channel.
+ *
+ * Return the size of the "lttng_event" array. Caller must free(3).
+ */
+extern int lttng_list_events(struct lttng_domain *domain,
+               const char *session_name, const char *channel_name,
+               struct lttng_event **events);
+
+/*
+ * List available tracepoints of domain.
+ *
+ * Return the size of the "lttng_event" array. Caller must free(3).
+ */
+extern int lttng_list_tracepoints(struct lttng_domain *domain,
+               struct lttng_event **events);
+
 /*
  * Check if a session daemon is alive.
  */
@@ -300,10 +342,9 @@ extern int lttng_disable_channel(struct lttng_domain *domain,
                const char *name);
 
 /*
- * List kernel events.
- *
- * Return the size of the allocated event list. Caller must free(3) the data.
+ * Calibrate LTTng overhead.
  */
-extern int lttng_list_events(struct lttng_domain *domain, char **event_list);
+extern int lttng_calibrate(struct lttng_domain *domain,
+               struct lttng_calibrate *calibrate);
 
 #endif /* _LTTNG_H */
This page took 0.024199 seconds and 4 git commands to generate.