#include <urcu/list.h>
+#include <lttng/domain-internal.h>
#include <common/mi-lttng.h>
#include "../command.h"
} else {
if (opt_channel_name) {
MSG("%s context %s added to channel %s",
- get_domain_str(dom.type), type->opt->symbol,
+ lttng_domain_type_str(dom.type),
+ type->opt->symbol,
opt_channel_name);
} else {
MSG("%s context %s added to all channels",
- get_domain_str(dom.type), type->opt->symbol);
+ lttng_domain_type_str(dom.type),
+ type->opt->symbol);
}
success = 1;
}
#include "common/mi-lttng.h"
#include "common/string-utils/string-utils.h"
#include "common/utils.h"
+#include <lttng/domain-internal.h>
/* For lttng_event_rule_type_str(). */
#include <lttng/event-rule/event-rule-internal.h>
#include <lttng/lttng.h>
#include <assert.h>
#include <common/mi-lttng.h>
+#include <lttng/domain-internal.h>
#include "../command.h"
} else {
MSG("%s channel %s disabled for session %s",
- get_domain_str(dom.type), channel_name, session_name);
+ lttng_domain_type_str(dom.type),
+ channel_name, session_name);
enabled = 0;
success = 1;
}
#include <assert.h>
#include <common/mi-lttng.h>
+#include <lttng/domain-internal.h>
#include "../command.h"
enabled = 0;
success = 1;
MSG("All %s events of type %s are disabled in channel %s",
- get_domain_str(dom.type),
+ lttng_domain_type_str(dom.type),
print_event_type(opt_event_type),
print_channel_name(channel_name));
}
enabled = 1;
} else {
MSG("%s %s of type %s disabled in channel %s for session %s",
- get_domain_str(dom.type),
+ lttng_domain_type_str(dom.type),
event_name,
print_event_type(opt_event_type),
print_channel_name(channel_name),
#include <common/utils.h>
#include <common/mi-lttng.h>
+#include <lttng/domain-internal.h>
+
#include "../command.h"
#include "../utils.h"
}
} else {
MSG("%s channel %s enabled for session %s",
- get_domain_str(dom.type), channel_name, session_name);
+ lttng_domain_type_str(dom.type),
+ channel_name, session_name);
success = 1;
}
/* Mi dependancy */
#include <common/mi-lttng.h>
+#include <lttng/domain-internal.h>
#include <lttng/event-internal.h>
#include "../command.h"
case LTTNG_DOMAIN_LOG4J:
case LTTNG_DOMAIN_PYTHON:
ERR("Event name exclusions are not yet implemented for %s events",
- get_domain_str(dom.type));
+ lttng_domain_type_str(dom.type));
ret = CMD_ERROR;
goto error;
case LTTNG_DOMAIN_UST:
goto end;
}
MSG("All %s tracepoints%s are enabled in channel %s for loglevel %s",
- get_domain_str(dom.type),
+ lttng_domain_type_str(dom.type),
exclusion_string,
print_channel_name(channel_name),
opt_loglevel);
goto end;
}
MSG("All %s tracepoints%s are enabled in channel %s",
- get_domain_str(dom.type),
+ lttng_domain_type_str(dom.type),
exclusion_string,
print_channel_name(channel_name));
free(exclusion_string);
case LTTNG_EVENT_SYSCALL:
if (opt_kernel) {
MSG("All %s system calls are enabled in channel %s",
- get_domain_str(dom.type),
+ lttng_domain_type_str(dom.type),
print_channel_name(channel_name));
}
break;
goto end;
}
MSG("All %s events%s are enabled in channel %s for loglevel %s",
- get_domain_str(dom.type),
+ lttng_domain_type_str(dom.type),
exclusion_string,
print_channel_name(channel_name),
opt_loglevel);
goto end;
}
MSG("All %s events%s are enabled in channel %s",
- get_domain_str(dom.type),
+ lttng_domain_type_str(dom.type),
exclusion_string,
print_channel_name(channel_name));
free(exclusion_string);
case LTTNG_DOMAIN_KERNEL:
case LTTNG_DOMAIN_UST:
MSG("%s event %s%s created in channel %s",
- get_domain_str(dom.type),
+ lttng_domain_type_str(dom.type),
event_name,
exclusion_string,
print_channel_name(channel_name));
* name for agent domains.
*/
MSG("%s event %s%s enabled",
- get_domain_str(dom.type),
+ lttng_domain_type_str(dom.type),
event_name,
exclusion_string);
break;
#include <common/mi-lttng.h>
#include <common/time.h>
#include <common/tracker.h>
+#include <lttng/domain-internal.h>
#include <lttng/lttng.h>
#include "../command.h"
goto error;
}
- agent_domain_str = get_domain_str(domain.type);
+ agent_domain_str = lttng_domain_type_str(domain.type);
DBG("Getting %s tracing events", agent_domain_str);
#include "utils.h"
#include "command.h"
-static const char *str_kernel = "Kernel";
-static const char *str_ust = "UST";
-static const char *str_jul = "JUL";
-static const char *str_log4j = "LOG4J";
-static const char *str_python = "Python";
static const char *str_all = "ALL";
static const char *str_tracepoint = "Tracepoint";
static const char *str_syscall = "Syscall";
return fls_ulong(x - 1);
}
-const char *get_domain_str(enum lttng_domain_type domain)
-{
- const char *str_dom;
-
- switch (domain) {
- case LTTNG_DOMAIN_KERNEL:
- str_dom = str_kernel;
- break;
- case LTTNG_DOMAIN_UST:
- str_dom = str_ust;
- break;
- case LTTNG_DOMAIN_JUL:
- str_dom = str_jul;
- break;
- case LTTNG_DOMAIN_LOG4J:
- str_dom = str_log4j;
- break;
- case LTTNG_DOMAIN_PYTHON:
- str_dom = str_python;
- break;
- default:
- /* Should not have an unknown domain or else define it. */
- assert(0);
- }
-
- return str_dom;
-}
-
const char *get_event_type_str(enum lttng_event_type type)
{
const char *str_event_type;
*/
int get_count_order_ulong(unsigned long x);
-const char *get_domain_str(enum lttng_domain_type domain);
const char *get_event_type_str(enum lttng_event_type event_type);
int print_missing_or_multiple_domains(unsigned int domain_count,
LTTNG_HIDDEN
const char *mi_lttng_domaintype_string(enum lttng_domain_type value)
{
- /* Note: This is a *duplicate* of get_domain_str from bin/lttng/utils.c */
switch (value) {
case LTTNG_DOMAIN_KERNEL:
return config_domain_type_kernel;