int has_enablers_without_bytecode;
};
-enum lttng_enabler_type {
- LTTNG_ENABLER_STAR_GLOB,
- LTTNG_ENABLER_NAME,
+enum lttng_enabler_format_type {
+ LTTNG_ENABLER_FORMAT_STAR_GLOB,
+ LTTNG_ENABLER_FORMAT_NAME,
};
/*
struct lttng_enabler {
enum lttng_event_type evtype; /* First field. */
- enum lttng_enabler_type type;
+ enum lttng_enabler_format_type format_type;
struct list_head node; /* per-session list of enablers */
/* head list of struct lttng_ust_filter_bytecode_node */
struct list_head *lttng_get_probe_list_head(void);
-struct lttng_enabler *lttng_enabler_create(enum lttng_enabler_type type,
+struct lttng_enabler *lttng_enabler_create(enum lttng_enabler_format_type format_type,
struct lttng_kernel_event *event_param,
struct lttng_channel *chan);
* If the event name is a star globbing pattern,
* we create the special star globbing enabler.
*/
- enabler = lttng_enabler_create(LTTNG_ENABLER_STAR_GLOB,
+ enabler = lttng_enabler_create(LTTNG_ENABLER_FORMAT_STAR_GLOB,
event_param, channel);
} else {
- enabler = lttng_enabler_create(LTTNG_ENABLER_NAME,
+ enabler = lttng_enabler_create(LTTNG_ENABLER_FORMAT_NAME,
event_param, channel);
}
priv = enabler;
switch (enabler->event_param.instrumentation) {
case LTTNG_KERNEL_TRACEPOINT:
desc_name = desc->name;
- switch (enabler->type) {
- case LTTNG_ENABLER_STAR_GLOB:
+ switch (enabler->format_type) {
+ case LTTNG_ENABLER_FORMAT_STAR_GLOB:
return lttng_match_enabler_star_glob(desc_name, enabler_name);
- case LTTNG_ENABLER_NAME:
+ case LTTNG_ENABLER_FORMAT_NAME:
return lttng_match_enabler_name(desc_name, enabler_name);
default:
return -EINVAL;
}
switch (enabler->event_param.u.syscall.match) {
case LTTNG_SYSCALL_MATCH_NAME:
- switch (enabler->type) {
- case LTTNG_ENABLER_STAR_GLOB:
+ switch (enabler->format_type) {
+ case LTTNG_ENABLER_FORMAT_STAR_GLOB:
return lttng_match_enabler_star_glob(desc_name, enabler_name);
- case LTTNG_ENABLER_NAME:
+ case LTTNG_ENABLER_FORMAT_NAME:
return lttng_match_enabler_name(desc_name, enabler_name);
default:
return -EINVAL;
return 0;
}
-struct lttng_enabler *lttng_enabler_create(enum lttng_enabler_type type,
+struct lttng_enabler *lttng_enabler_create(enum lttng_enabler_format_type format_type,
struct lttng_kernel_event *event_param,
struct lttng_channel *chan)
{
enabler = kzalloc(sizeof(*enabler), GFP_KERNEL);
if (!enabler)
return NULL;
- enabler->type = type;
+ enabler->format_type = format_type;
INIT_LIST_HEAD(&enabler->filter_bytecode_head);
memcpy(&enabler->event_param, event_param,
sizeof(enabler->event_param));