X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=liblttng-ust%2Flttng-tracer-core.h;h=52315a8de001227fecd02ae50749581b9a16edf9;hb=735bef4705cc42f25d26f25be09ba98f1efb8511;hp=4e0d2c69d70f2510811a80432e22ab2a43e79a3b;hpb=79f3848bb8124bfa476effa461d230cb9f54c7a2;p=lttng-ust.git diff --git a/liblttng-ust/lttng-tracer-core.h b/liblttng-ust/lttng-tracer-core.h index 4e0d2c69..52315a8d 100644 --- a/liblttng-ust/lttng-tracer-core.h +++ b/liblttng-ust/lttng-tracer-core.h @@ -30,9 +30,20 @@ #include #include +/* + * The longuest possible namespace proc path is with the cgroup ns + * and the maximum theoretical linux pid of 536870912 : + * + * /proc/self/task/536870912/ns/cgroup + */ +#define LTTNG_PROC_NS_PATH_MAX 40 + struct lttng_session; struct lttng_channel; struct lttng_event; +struct lttng_ctx_field; +struct lttng_ust_lib_ring_buffer_ctx; +struct lttng_ctx_value; int ust_lock(void) __attribute__ ((warn_unused_result)); void ust_lock_nocheck(void); @@ -41,6 +52,10 @@ void ust_unlock(void); void lttng_fixup_event_tls(void); void lttng_fixup_vtid_tls(void); void lttng_fixup_procname_tls(void); +void lttng_fixup_cgroup_ns_tls(void); +void lttng_fixup_ipc_ns_tls(void); +void lttng_fixup_net_ns_tls(void); +void lttng_fixup_uts_ns_tls(void); const char *lttng_ust_obj_get_name(int id); @@ -50,4 +65,34 @@ void lttng_ust_sockinfo_session_enabled(void *owner); void lttng_ust_malloc_wrapper_init(void); +ssize_t lttng_ust_read(int fd, void *buf, size_t len); + +size_t lttng_ust_dummy_get_size(struct lttng_ctx_field *field, size_t offset); +void lttng_ust_dummy_record(struct lttng_ctx_field *field, + struct lttng_ust_lib_ring_buffer_ctx *ctx, + struct lttng_channel *chan); +void lttng_ust_dummy_get_value(struct lttng_ctx_field *field, + struct lttng_ctx_value *value); +int lttng_context_is_app(const char *name); +void lttng_ust_fixup_tls(void); + +#ifdef LTTNG_UST_HAVE_PERF_EVENT +void lttng_ust_fixup_perf_counter_tls(void); +void lttng_perf_lock(void); +void lttng_perf_unlock(void); +#else /* #ifdef LTTNG_UST_HAVE_PERF_EVENT */ +static inline +void lttng_ust_fixup_perf_counter_tls(void) +{ +} +static inline +void lttng_perf_lock(void) +{ +} +static inline +void lttng_perf_unlock(void) +{ +} +#endif /* #else #ifdef LTTNG_UST_HAVE_PERF_EVENT */ + #endif /* _LTTNG_TRACER_CORE_H */