Move to kernel style SPDX license identifiers
[lttng-ust.git] / liblttng-ust-dl / ust_dl.h
CommitLineData
c0c0989a
MJ
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 */
7
b13d93c2 8#undef TRACEPOINT_PROVIDER
6d4658aa 9#define TRACEPOINT_PROVIDER lttng_ust_dl
b13d93c2 10
6d4658aa
AB
11#if !defined(_TRACEPOINT_UST_DL_H) || defined(TRACEPOINT_HEADER_MULTI_READ)
12#define _TRACEPOINT_UST_DL_H
b13d93c2
PW
13
14#ifdef __cplusplus
15extern "C" {
16#endif
17
b4051ad8 18#include <stddef.h>
b13d93c2
PW
19#include <stdint.h>
20#include <unistd.h>
21
6d4658aa 22#define LTTNG_UST_DL_PROVIDER
b13d93c2
PW
23#include <lttng/tracepoint.h>
24
6d4658aa 25TRACEPOINT_EVENT(lttng_ust_dl, dlopen,
7b0fdd83
MD
26 TP_ARGS(void *, ip, void *, baddr, const char *, path,
27 int, flags, uint64_t, memsz, uint8_t, has_build_id,
28 uint8_t, has_debug_link),
29 TP_FIELDS(
30 ctf_integer_hex(void *, baddr, baddr)
31 ctf_integer(uint64_t, memsz, memsz)
32 ctf_integer_hex(int, flags, flags)
33 ctf_string(path, path)
34 ctf_integer(uint8_t, has_build_id, has_build_id)
35 ctf_integer(uint8_t, has_debug_link, has_debug_link)
36 )
37)
38
42330adc 39#ifdef HAVE_DLMOPEN
7b0fdd83
MD
40TRACEPOINT_EVENT(lttng_ust_dl, dlmopen,
41 TP_ARGS(void *, ip, void *, baddr, Lmid_t, nsid,
42 const char *, path, int, flags,
c5c4fd82
MD
43 uint64_t, memsz, uint8_t, has_build_id,
44 uint8_t, has_debug_link),
b13d93c2
PW
45 TP_FIELDS(
46 ctf_integer_hex(void *, baddr, baddr)
8e2aed3f 47 ctf_integer(uint64_t, memsz, memsz)
7b0fdd83
MD
48 ctf_integer(Lmid_t, nsid, nsid)
49 ctf_integer_hex(int, flags, flags)
f60e49df 50 ctf_string(path, path)
c5c4fd82
MD
51 ctf_integer(uint8_t, has_build_id, has_build_id)
52 ctf_integer(uint8_t, has_debug_link, has_debug_link)
8e2aed3f
AB
53 )
54)
42330adc 55#endif
8e2aed3f
AB
56
57TRACEPOINT_EVENT(lttng_ust_dl, build_id,
58 TP_ARGS(
59 void *, ip,
60 void *, baddr,
61 uint8_t *, build_id,
62 size_t, build_id_len
63 ),
64 TP_FIELDS(
65 ctf_integer_hex(void *, baddr, baddr)
66 ctf_sequence_hex(uint8_t, build_id, build_id,
67 size_t, build_id_len)
68 )
69)
70
71TRACEPOINT_EVENT(lttng_ust_dl, debug_link,
72 TP_ARGS(
73 void *, ip,
74 void *, baddr,
75 char *, filename,
76 uint32_t, crc
77 ),
78 TP_FIELDS(
79 ctf_integer_hex(void *, baddr, baddr)
80 ctf_integer(uint32_t, crc, crc)
81 ctf_string(filename, filename)
b13d93c2
PW
82 )
83)
84
6d4658aa 85TRACEPOINT_EVENT(lttng_ust_dl, dlclose,
8e2aed3f 86 TP_ARGS(void *, ip, void *, baddr),
b13d93c2
PW
87 TP_FIELDS(
88 ctf_integer_hex(void *, baddr, baddr)
89 )
90)
91
6d4658aa 92#endif /* _TRACEPOINT_UST_DL_H */
b13d93c2
PW
93
94#undef TRACEPOINT_INCLUDE
6d4658aa 95#define TRACEPOINT_INCLUDE "./ust_dl.h"
b13d93c2
PW
96
97/* This part must be outside ifdef protection */
98#include <lttng/tracepoint-event.h>
99
100#ifdef __cplusplus
101}
102#endif
This page took 0.028953 seconds and 4 git commands to generate.