f60e8fd7a7e8ad09bd7b8d625ac93718617ca44e
[lttng-ust.git] / src / lib / lttng-ust / ust_lib.h
1 /*
2 * SPDX-License-Identifier: MIT
3 *
4 * Copyright (C) 2013 Paul Woegerer <paul_woegerer@mentor.com>
5 * Copyright (C) 2015 Antoine Busque <abusque@efficios.com>
6 * Copyright (C) 2016 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
7 */
8
9 #undef LTTNG_UST_TRACEPOINT_PROVIDER
10 #define LTTNG_UST_TRACEPOINT_PROVIDER lttng_ust_lib
11
12 #if !defined(_TRACEPOINT_UST_LIB_H) || defined(LTTNG_UST_TRACEPOINT_HEADER_MULTI_READ)
13 #define _TRACEPOINT_UST_LIB_H
14
15 #ifdef __cplusplus
16 extern "C" {
17 #endif
18
19 #include <stddef.h>
20 #include <stdint.h>
21 #include <unistd.h>
22
23 #define LTTNG_UST_LIB_PROVIDER
24 #include <lttng/tracepoint.h>
25
26 LTTNG_UST_TRACEPOINT_EVENT(lttng_ust_lib, load,
27 LTTNG_UST_TP_ARGS(void *, ip, void *, baddr, const char*, path,
28 uint64_t, memsz, uint8_t, has_build_id,
29 uint8_t, has_debug_link),
30 LTTNG_UST_TP_FIELDS(
31 ctf_unused(ip)
32 lttng_ust_field_integer_hex(void *, baddr, baddr)
33 lttng_ust_field_integer(uint64_t, memsz, memsz)
34 ctf_string(path, path)
35 lttng_ust_field_integer(uint8_t, has_build_id, has_build_id)
36 lttng_ust_field_integer(uint8_t, has_debug_link, has_debug_link)
37 )
38 )
39
40 LTTNG_UST_TRACEPOINT_EVENT(lttng_ust_lib, build_id,
41 LTTNG_UST_TP_ARGS(
42 void *, ip,
43 void *, baddr,
44 uint8_t *, build_id,
45 size_t, build_id_len
46 ),
47 LTTNG_UST_TP_FIELDS(
48 ctf_unused(ip)
49 lttng_ust_field_integer_hex(void *, baddr, baddr)
50 ctf_sequence_hex(uint8_t, build_id, build_id,
51 size_t, build_id_len)
52 )
53 )
54
55 LTTNG_UST_TRACEPOINT_EVENT(lttng_ust_lib, debug_link,
56 LTTNG_UST_TP_ARGS(
57 void *, ip,
58 void *, baddr,
59 char *, filename,
60 uint32_t, crc
61 ),
62 LTTNG_UST_TP_FIELDS(
63 ctf_unused(ip)
64 lttng_ust_field_integer_hex(void *, baddr, baddr)
65 lttng_ust_field_integer(uint32_t, crc, crc)
66 ctf_string(filename, filename)
67 )
68 )
69
70 LTTNG_UST_TRACEPOINT_EVENT(lttng_ust_lib, unload,
71 LTTNG_UST_TP_ARGS(void *, ip, void *, baddr),
72 LTTNG_UST_TP_FIELDS(
73 ctf_unused(ip)
74 lttng_ust_field_integer_hex(void *, baddr, baddr)
75 )
76 )
77
78 #endif /* _TRACEPOINT_UST_LIB_H */
79
80 #undef LTTNG_UST_TRACEPOINT_INCLUDE
81 #define LTTNG_UST_TRACEPOINT_INCLUDE "./ust_lib.h"
82
83 /* This part must be outside ifdef protection */
84 #include <lttng/tracepoint-event.h>
85
86 #ifdef __cplusplus
87 }
88 #endif
This page took 0.029534 seconds and 3 git commands to generate.