From 8812e921083147264ac4a299748ca6d4077e5233 Mon Sep 17 00:00:00 2001 From: Mathieu Desnoyers Date: Fri, 23 Apr 2021 20:05:40 -0400 Subject: [PATCH] tracepoint: Declare tracepoint module register/unregister API The registration/unregistration API is part of the ABI, and used through dlopen/dlsym, but its declaration is not exposed in the API. Add the missing declarations. Also remove useless "extern" on lttng_ust_tracepoint_provider_register/unregister. Signed-off-by: Mathieu Desnoyers Change-Id: I0aecdf02c0dd604f960dc49ec4aa71613474c9b6 --- include/lttng/tracepoint.h | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/include/lttng/tracepoint.h b/include/lttng/tracepoint.h index f2a65777..c59a96c9 100644 --- a/include/lttng/tracepoint.h +++ b/include/lttng/tracepoint.h @@ -230,11 +230,24 @@ void lttng_ust_tracepoint_unregister_##_provider##___##_name(char *provider_name lttng_ust_tracepoint_provider_unregister(provider_name, event_name, func, data); \ } -extern int lttng_ust_tracepoint_provider_register(const char *provider_name, const char *event_name, +/* + * Registration of tracepoint provider probe functions with + * lttng_ust_tracepoint_provider_register, unregistration with + * lttng_ust_tracepoint_provider_unregister. + */ +int lttng_ust_tracepoint_provider_register(const char *provider_name, const char *event_name, void (*func)(void), void *data, const char *signature); -extern int lttng_ust_tracepoint_provider_unregister(const char *provider_name, const char *event_name, +int lttng_ust_tracepoint_provider_unregister(const char *provider_name, const char *event_name, void (*func)(void), void *data); +/* + * Registration of tracepoint instrumentation modules with lttng_ust_tracepoint_module_register, + * unregistration with lttng_ust_tracepoint_module_unregister. + */ +int lttng_ust_tracepoint_module_register(struct lttng_ust_tracepoint * const *tracepoints_start, + int tracepoints_count); +int lttng_ust_tracepoint_module_unregister(struct lttng_ust_tracepoint * const *tracepoints_start); + /* * tracepoint dynamic linkage handling (callbacks). Hidden visibility: * shared across objects in a module/main executable. -- 2.34.1