X-Git-Url: https://git.liburcu.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Flttng-ust-ctl.h;h=73a9244187aa9c6aef8536749439cd6482e6228b;hp=b3de5a9ba61846f557ec39b0df4cecd1b486bca1;hb=10b56aefc3e1de5cee607994f64c3b8a7d85c391;hpb=c82fce01c4a94b36b54149f46b1824ec10321734 diff --git a/src/bin/lttng-sessiond/lttng-ust-ctl.h b/src/bin/lttng-sessiond/lttng-ust-ctl.h index b3de5a9ba..73a924418 100644 --- a/src/bin/lttng-sessiond/lttng-ust-ctl.h +++ b/src/bin/lttng-sessiond/lttng-ust-ctl.h @@ -227,6 +227,7 @@ enum ustctl_socket_type { enum ustctl_notify_cmd { USTCTL_NOTIFY_CMD_EVENT = 0, USTCTL_NOTIFY_CMD_CHANNEL = 1, + USTCTL_NOTIFY_CMD_ENUM = 2, }; enum ustctl_channel_header { @@ -274,6 +275,13 @@ struct ustctl_float_type { char padding[USTCTL_UST_FLOAT_TYPE_PADDING]; } LTTNG_PACKED; +#define USTCTL_UST_ENUM_ENTRY_PADDING 32 +struct ustctl_enum_entry { + uint64_t start, end; /* start and end are inclusive */ + char string[LTTNG_UST_SYM_NAME_LEN]; + char padding[USTCTL_UST_ENUM_ENTRY_PADDING]; +}; + #define USTCTL_UST_BASIC_TYPE_PADDING 296 union _ustctl_basic_type { struct ustctl_integer_type integer; @@ -281,6 +289,9 @@ union _ustctl_basic_type { enum ustctl_string_encodings encoding; } string; struct ustctl_float_type _float; + struct { + char name[LTTNG_UST_SYM_NAME_LEN]; + } enumeration; char padding[USTCTL_UST_BASIC_TYPE_PADDING]; } LTTNG_PACKED; @@ -375,6 +386,22 @@ int ustctl_reply_register_event(int sock, uint32_t id, /* event id (input) */ int ret_code); /* return code. 0 ok, negative error */ +/* + * Returns 0 on success, negative UST or system error value on error. + */ +int ustctl_recv_register_enum(int sock, + int *session_objd, + char *enum_name, + struct ustctl_enum_entry **entries, + unsigned int *nr_entries); + +/* + * Returns 0 on success, negative error value on error. + */ +int ustctl_reply_register_enum(int sock, + int64_t id, /* enum id (input) */ + int ret_code); + /* * Returns 0 on success, negative UST or system error value on error. */