Fix errors due to lttng.h cleanup
[lttng-tools.git] / liblttngctl / liblttngctl.c
index a2934e63c9644e3e70ae3b7309880b4857e9b2bd..c27ce092825595692b91e4552b250a190dcf486f 100644 (file)
@@ -154,7 +154,6 @@ static int ask_sessiond(enum lttcomm_sessiond_command lct, void **buf)
 
 end:
        lttng_disconnect_sessiond();
-       memset(&lsm, 0, sizeof(lsm));
        return ret;
 }
 
@@ -199,21 +198,31 @@ int lttng_kernel_create_session(void)
  *
  *  Create a channel in the kernel tracer.
  */
-int lttng_kernel_create_channel(int overwrite,
-               u64 subbuf_size, u64 num_subbuf,
-               unsigned int switch_timer_interval,
-               unsigned int read_timer_interval)
+int lttng_kernel_create_channel(void)
 {
-       /* Write setting to the session message */
-       lsm.u.create_channel.overwrite = overwrite;
-       lsm.u.create_channel.subbuf_size = subbuf_size;
-       lsm.u.create_channel.num_subbuf = num_subbuf;
-       lsm.u.create_channel.switch_timer_interval = switch_timer_interval;
-       lsm.u.create_channel.read_timer_interval = read_timer_interval;
-
        return ask_sessiond(KERNEL_CREATE_CHANNEL, NULL);
 }
 
+/*
+ *  lttng_kernel_open_metadata
+ *
+ *  Open metadata in the kernel tracer.
+ */
+int lttng_kernel_open_metadata(void)
+{
+       return ask_sessiond(KERNEL_OPEN_METADATA, NULL);
+}
+
+/*
+ *  lttng_kernel_create_stream
+ *
+ *  Create stream in the kernel tracer.
+ */
+int lttng_kernel_create_stream(void)
+{
+       return ask_sessiond(KERNEL_CREATE_STREAM, NULL);
+}
+
 /*
  *  lttng_kernel_start_tracing
  *
@@ -343,10 +352,9 @@ int lttng_list_traces(uuid_t *uuid, struct lttng_trace **traces)
 /*
  *  lttng_create_session
  *
- *  Create a brand new session using name. Allocate
- *  the session_id param pointing to the UUID.
+ *  Create a brand new session using name.
  */
-int lttng_create_session(char *name, uuid_t *session_id)
+int lttng_create_session(char *name)
 {
        int ret;
 
@@ -358,8 +366,6 @@ int lttng_create_session(char *name, uuid_t *session_id)
                goto end;
        }
 
-       uuid_copy(*session_id, llm.session_uuid);
-
 end:
        return ret;
 }
@@ -582,5 +588,5 @@ end:
 static void __attribute__((constructor)) init()
 {
        /* Set default session group */
-       lttng_set_tracing_group(DEFAULT_TRACING_GROUP);
+       lttng_set_tracing_group(LTTNG_DEFAULT_TRACING_GROUP);
 }
This page took 0.026372 seconds and 5 git commands to generate.