X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;ds=sidebyside;f=include%2Flttng%2Fust-ctl.h;h=a067480b0bc8cff9aa9d9389680432f313f715a0;hb=00b217e613614b8addc4ee2bbcdec473275842fd;hp=10602ee73c4d3cf66433549b213c6c03ca6f2531;hpb=e92f3e285939848f248af08f11a39a04a7fcf852;p=lttng-ust.git diff --git a/include/lttng/ust-ctl.h b/include/lttng/ust-ctl.h index 10602ee7..a067480b 100644 --- a/include/lttng/ust-ctl.h +++ b/include/lttng/ust-ctl.h @@ -21,6 +21,11 @@ #include +/* + * Error values: all the following functions return: + * >= 0: Success (LTTNG_UST_OK) + * < 0: error code. + */ int ustctl_register_done(int sock); int ustctl_create_session(int sock); int ustctl_open_metadata(int sock, int session_handle, @@ -29,20 +34,29 @@ int ustctl_open_metadata(int sock, int session_handle, int ustctl_create_channel(int sock, int session_handle, struct lttng_ust_channel_attr *chops, struct lttng_ust_object_data **channel_data); -int ustctl_create_stream(int sock, struct lttng_ust_object_data *channel_data, - struct lttng_ust_object_data **stream_data); int ustctl_create_event(int sock, struct lttng_ust_event *ev, struct lttng_ust_object_data *channel_data, struct lttng_ust_object_data **event_data); int ustctl_add_context(int sock, struct lttng_ust_context *ctx, struct lttng_ust_object_data *obj_data, struct lttng_ust_object_data **context_data); +int ustctl_set_filter(int sock, struct lttng_ust_filter_bytecode *bytecode, + struct lttng_ust_object_data *obj_data); int ustctl_enable(int sock, struct lttng_ust_object_data *object); int ustctl_disable(int sock, struct lttng_ust_object_data *object); int ustctl_start_session(int sock, int handle); int ustctl_stop_session(int sock, int handle); +/* + * Return -LTTNG_UST_ERR_NOENT if no more stream is available for creation. + * Return 0 on success. + * Return negative error value on system error. + * Return positive error value on UST error. + */ +int ustctl_create_stream(int sock, struct lttng_ust_object_data *channel_data, + struct lttng_ust_object_data **stream_data); + /* * ustctl_tracepoint_list returns a tracepoint list handle, or negative * error value. @@ -50,11 +64,26 @@ int ustctl_stop_session(int sock, int handle); int ustctl_tracepoint_list(int sock); /* * ustctl_tracepoint_list_get is used to iterate on the tp list - * handle. End is iteration is reached when -ENOENT is returned. + * handle. End is iteration is reached when -LTTNG_UST_ERR_NOENT is + * returned. */ int ustctl_tracepoint_list_get(int sock, int tp_list_handle, struct lttng_ust_tracepoint_iter *iter); +/* + * ustctl_tracepoint_field_list returns a tracepoint field list handle, + * or negative error value. + */ +int ustctl_tracepoint_field_list(int sock); + +/* + * ustctl_tracepoint_field_list_get is used to iterate on the tp field + * list handle. End is iteration is reached when -LTTNG_UST_ERR_NOENT is + * returned. + */ +int ustctl_tracepoint_field_list_get(int sock, int tp_field_list_handle, + struct lttng_ust_field_iter *iter); + int ustctl_tracer_version(int sock, struct lttng_ust_tracer_version *v); int ustctl_wait_quiescent(int sock);