2 * Copyright (C) 2012 - Christian Babeux <christian.babeux@efficios.com>
3 * Copyright (C) 2014 - Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License, version 2 only, as
7 * published by the Free Software Foundation.
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14 * You should have received a copy of the GNU General Public License along with
15 * this program; if not, write to the Free Software Foundation, Inc., 51
16 * Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
25 * Check if the specified environment variable is set.
26 * Return 1 if set, otherwise 0.
29 int check_env_var(const char *env
)
32 char *env_val
= getenv(env
);
33 if (env_val
&& (strncmp(env_val
, "1", 1) == 0)) {
43 int __testpoint_sessiond_thread_manage_clients(void)
45 const char *var
= "LTTNG_SESSIOND_THREAD_MANAGE_CLIENTS_EXIT";
47 if (check_env_var(var
)) {
48 rcu_unregister_thread();
55 int __testpoint_sessiond_thread_registration_apps(void)
57 const char *var
= "LTTNG_SESSIOND_THREAD_REG_APPS_EXIT";
59 if (check_env_var(var
)) {
66 int __testpoint_sessiond_thread_manage_apps(void)
68 const char *var
= "LTTNG_SESSIOND_THREAD_MANAGE_APPS_EXIT";
70 if (check_env_var(var
)) {
71 rcu_unregister_thread();
78 int __testpoint_sessiond_thread_manage_kernel(void)
80 const char *var
= "LTTNG_SESSIOND_THREAD_MANAGE_KERNEL_EXIT";
82 if (check_env_var(var
)) {
89 int __testpoint_sessiond_thread_manage_consumer(void)
91 const char *var
= "LTTNG_SESSIOND_THREAD_MANAGE_CONSUMER_EXIT";
93 if (check_env_var(var
)) {
100 int __testpoint_sessiond_thread_ht_cleanup(void)
102 const char *var
= "LTTNG_SESSIOND_THREAD_HT_CLEANUP_EXIT";
104 if (check_env_var(var
)) {
105 rcu_unregister_thread();
112 int __testpoint_sessiond_thread_app_manage_notify(void)
114 const char *var
= "LTTNG_SESSIOND_THREAD_APP_MANAGE_NOTIFY_EXIT";
116 if (check_env_var(var
)) {
117 rcu_unregister_thread();
124 int __testpoint_sessiond_thread_app_reg_dispatch(void)
126 const char *var
= "LTTNG_SESSIOND_THREAD_APP_REG_DISPATCH_EXIT";
128 if (check_env_var(var
)) {
135 /* Consumer daemon */
137 int __testpoint_consumerd_thread_channel(void)
139 const char *var
= "LTTNG_CONSUMERD_THREAD_CHANNEL_EXIT";
141 if (check_env_var(var
)) {
142 rcu_unregister_thread();
149 int __testpoint_consumerd_thread_metadata(void)
151 const char *var
= "LTTNG_CONSUMERD_THREAD_METADATA_EXIT";
153 if (check_env_var(var
)) {
154 rcu_unregister_thread();
161 int __testpoint_consumerd_thread_data(void)
163 const char *var
= "LTTNG_CONSUMERD_THREAD_DATA_EXIT";
165 if (check_env_var(var
)) {
166 rcu_unregister_thread();
173 int __testpoint_consumerd_thread_sessiond(void)
175 const char *var
= "LTTNG_CONSUMERD_THREAD_SESSIOND_EXIT";
177 if (check_env_var(var
)) {
178 rcu_unregister_thread();
185 int __testpoint_consumerd_thread_metadata_timer(void)
187 const char *var
= "LTTNG_CONSUMERD_THREAD_METADATA_TIMER_EXIT";
189 if (check_env_var(var
)) {
198 int __testpoint_relayd_thread_dispatcher(void)
200 const char *var
= "LTTNG_RELAYD_THREAD_DISPATCHER_EXIT";
202 if (check_env_var(var
)) {
209 int __testpoint_relayd_thread_worker(void)
211 const char *var
= "LTTNG_RELAYD_THREAD_WORKER_EXIT";
213 if (check_env_var(var
)) {
214 rcu_unregister_thread();
221 int __testpoint_relayd_thread_listener(void)
223 const char *var
= "LTTNG_RELAYD_THREAD_LISTENER_EXIT";
225 if (check_env_var(var
)) {
232 int __testpoint_relayd_thread_live_dispatcher(void)
234 const char *var
= "LTTNG_RELAYD_THREAD_LIVE_DISPATCHER_EXIT";
236 if (check_env_var(var
)) {
243 int __testpoint_relayd_thread_live_worker(void)
245 const char *var
= "LTTNG_RELAYD_THREAD_LIVE_WORKER_EXIT";
247 if (check_env_var(var
)) {
248 rcu_unregister_thread();
255 int __testpoint_relayd_thread_live_listener(void)
257 const char *var
= "LTTNG_RELAYD_THREAD_LIVE_LISTENER_EXIT";
259 if (check_env_var(var
)) {
This page took 0.03633 seconds and 5 git commands to generate.