Hide new 'lttng_fixup_time_ns_tls' private symbol
[lttng-ust.git] / liblttng-ust / lttng-tracer-core.h
CommitLineData
7dd08bec
MD
1#ifndef _LTTNG_TRACER_CORE_H
2#define _LTTNG_TRACER_CORE_H
4fbf9cd1
MD
3
4/*
5 * Copyright (C) 2005-2011 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
6 *
7 * This contains the core definitions for the Linux Trace Toolkit.
8 *
9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Lesser General Public
11 * License as published by the Free Software Foundation; version 2.1 of
12 * the License.
13 *
14 * This library is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 * Lesser General Public License for more details.
18 *
19 * You should have received a copy of the GNU Lesser General Public
20 * License along with this library; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
22 */
23
b728d87e
MD
24#include <stddef.h>
25#include <urcu/arch.h>
4fbf9cd1 26#include <urcu/list.h>
44c72f10
MD
27#include <lttng/ust-tracer.h>
28#include <lttng/bug.h>
4318ae1b 29#include <lttng/ringbuffer-config.h>
44c72f10 30#include <usterr-signal-safe.h>
94be38e8 31#include <helper.h>
4fbf9cd1 32
735bef47
MJ
33/*
34 * The longuest possible namespace proc path is with the cgroup ns
35 * and the maximum theoretical linux pid of 536870912 :
36 *
37 * /proc/self/task/536870912/ns/cgroup
38 */
39#define LTTNG_PROC_NS_PATH_MAX 40
40
7dd08bec
MD
41struct lttng_session;
42struct lttng_channel;
43struct lttng_event;
ce7352a2
MD
44struct lttng_ctx_field;
45struct lttng_ust_lib_ring_buffer_ctx;
46struct lttng_ctx_value;
850550e0 47struct lttng_event_notifier;
4fbf9cd1 48
3327ac33
MD
49int ust_lock(void) __attribute__ ((warn_unused_result));
50void ust_lock_nocheck(void);
17dfb34b 51void ust_unlock(void);
8165c8da 52
eddd8d5d 53void lttng_fixup_event_tls(void);
4158a15a 54void lttng_fixup_vtid_tls(void);
009745db 55void lttng_fixup_procname_tls(void);
735bef47
MJ
56void lttng_fixup_cgroup_ns_tls(void);
57void lttng_fixup_ipc_ns_tls(void);
58void lttng_fixup_net_ns_tls(void);
3046e0bf 59LTTNG_HIDDEN
cefef7a7 60void lttng_fixup_time_ns_tls(void);
735bef47 61void lttng_fixup_uts_ns_tls(void);
eddd8d5d 62
74d81a6c
MD
63const char *lttng_ust_obj_get_name(int id);
64
32ce8569
MD
65int lttng_get_notify_socket(void *owner);
66
94be38e8
JR
67LTTNG_HIDDEN
68char* lttng_ust_sockinfo_get_procname(void *owner);
69
246be17e 70void lttng_ust_sockinfo_session_enabled(void *owner);
95c25348 71
79f3848b
MD
72void lttng_ust_malloc_wrapper_init(void);
73
405be658
MD
74ssize_t lttng_ust_read(int fd, void *buf, size_t len);
75
ce7352a2
MD
76size_t lttng_ust_dummy_get_size(struct lttng_ctx_field *field, size_t offset);
77void lttng_ust_dummy_record(struct lttng_ctx_field *field,
78 struct lttng_ust_lib_ring_buffer_ctx *ctx,
79 struct lttng_channel *chan);
80void lttng_ust_dummy_get_value(struct lttng_ctx_field *field,
81 struct lttng_ctx_value *value);
82int lttng_context_is_app(const char *name);
c362addf 83void lttng_ust_fixup_tls(void);
ce7352a2 84
10544ee8
MD
85extern void (*lttng_ust_liburcu_bp_before_fork)(void);
86extern void (*lttng_ust_liburcu_bp_after_fork_parent)(void);
87extern void (*lttng_ust_liburcu_bp_after_fork_child)(void);
88
cab88ff8
MD
89LTTNG_HIDDEN
90void lttng_event_notifier_notification_send(
91 struct lttng_event_notifier *event_notifier,
92 const char *stack_data);
93
20142124
MD
94#ifdef LTTNG_UST_HAVE_PERF_EVENT
95void lttng_ust_fixup_perf_counter_tls(void);
96void lttng_perf_lock(void);
97void lttng_perf_unlock(void);
98#else /* #ifdef LTTNG_UST_HAVE_PERF_EVENT */
99static inline
100void lttng_ust_fixup_perf_counter_tls(void)
101{
102}
103static inline
104void lttng_perf_lock(void)
105{
106}
107static inline
108void lttng_perf_unlock(void)
109{
110}
111#endif /* #else #ifdef LTTNG_UST_HAVE_PERF_EVENT */
112
7dd08bec 113#endif /* _LTTNG_TRACER_CORE_H */
This page took 0.035922 seconds and 4 git commands to generate.