SoW-2020-0002: Trace Hit Counters: trigger error reporting integration
[lttng-tools.git] / src / bin / lttng-sessiond / globals.c
CommitLineData
a7333da7 1/*
ab5be9fa
MJ
2 * Copyright (C) 2011 David Goulet <david.goulet@polymtl.ca>
3 * Copyright (C) 2011 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
4 * Copyright (C) 2013 Jérémie Galarneau <jeremie.galarneau@efficios.com>
a7333da7 5 *
ab5be9fa 6 * SPDX-License-Identifier: GPL-2.0-only
a7333da7 7 *
a7333da7
JG
8 */
9
10#include "lttng-sessiond.h"
c70636a7 11#include <common/uuid.h>
52a0e931
JG
12
13lttng_uuid sessiond_uuid;
a7333da7
JG
14
15int ust_consumerd64_fd = -1;
16int ust_consumerd32_fd = -1;
17
18long page_size;
19
20struct health_app *health_sessiond;
21
22struct notification_thread_handle *notification_thread_handle;
2463b787 23pthread_mutex_t notification_trigger_tokens_ht_lock = PTHREAD_MUTEX_INITIALIZER;
a7333da7
JG
24
25struct lttng_ht *agent_apps_ht_by_sock = NULL;
2463b787 26struct lttng_ht *trigger_agents_ht_by_domain = NULL;
a7333da7 27
917a718d
JG
28struct lttng_kernel_tracer_version kernel_tracer_version;
29struct lttng_kernel_tracer_abi_version kernel_tracer_abi_version;
a7333da7 30
e32d7f27 31int kernel_poll_pipe[2] = { -1, -1 };
a7333da7
JG
32
33pid_t ppid;
34pid_t child_ppid;
35
36struct sessiond_config config;
917a718d
JG
37
38struct consumer_data kconsumer_data = {
39 .type = LTTNG_CONSUMER_KERNEL,
40 .err_sock = -1,
41 .cmd_sock = -1,
42 .channel_monitor_pipe = -1,
43 .pid_mutex = PTHREAD_MUTEX_INITIALIZER,
44 .lock = PTHREAD_MUTEX_INITIALIZER,
917a718d
JG
45};
46
47struct consumer_data ustconsumer64_data = {
48 .type = LTTNG_CONSUMER64_UST,
49 .err_sock = -1,
50 .cmd_sock = -1,
51 .channel_monitor_pipe = -1,
52 .pid_mutex = PTHREAD_MUTEX_INITIALIZER,
53 .lock = PTHREAD_MUTEX_INITIALIZER,
917a718d
JG
54};
55
56struct consumer_data ustconsumer32_data = {
57 .type = LTTNG_CONSUMER32_UST,
58 .err_sock = -1,
59 .cmd_sock = -1,
60 .channel_monitor_pipe = -1,
61 .pid_mutex = PTHREAD_MUTEX_INITIALIZER,
62 .lock = PTHREAD_MUTEX_INITIALIZER,
917a718d
JG
63};
64
65enum consumerd_state ust_consumerd_state;
66enum consumerd_state kernel_consumerd_state;
52a0e931
JG
67
68static void __attribute__((constructor)) init_sessiond_uuid(void)
69{
70 if (lttng_uuid_generate(sessiond_uuid)) {
71 ERR("Failed to generate a session daemon UUID");
72 abort();
73 }
74}
This page took 0.060878 seconds and 5 git commands to generate.