X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=include%2Flttng%2Fust-ctl.h;h=11beabaadc63912f45774116c673a4f591fd82e0;hb=c7b9470b6849bc42d0c3a835b917e764e8c13fc9;hp=5f022c7102433a80161a25e5790f00d091b52b9d;hpb=cd54f6d934faf715cbd12fa9665e94b6fe367802;p=lttng-ust.git diff --git a/include/lttng/ust-ctl.h b/include/lttng/ust-ctl.h index 5f022c71..11beabaa 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,8 +34,6 @@ 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); @@ -45,6 +48,15 @@ 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 -ENOENT 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. @@ -52,7 +64,8 @@ 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); @@ -65,7 +78,8 @@ 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 -ENOENT is returned. + * 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);