Commit | Line | Data |
---|---|---|
82b9bde8 | 1 | /* |
c0c0989a | 2 | * SPDX-License-Identifier: LGPL-2.1-only |
82b9bde8 | 3 | * |
c0c0989a | 4 | * Copyright (C) 2013 Mathieu Desnoyers <mathieu.desnoyers@efficios.com> |
82b9bde8 JD |
5 | */ |
6 | ||
8cd08025 MJ |
7 | #ifndef _UST_COMMON_RINGBUFFER_CLIENTS_CLIENTS_H |
8 | #define _UST_COMMON_RINGBUFFER_CLIENTS_CLIENTS_H | |
c0c0989a | 9 | |
fb31eb73 | 10 | #include <stdint.h> |
8cd08025 MJ |
11 | #include <lttng/ust-events.h> |
12 | ||
e4db8f98 | 13 | #include "common/ringbuffer/ringbuffer-config.h" |
fb31eb73 | 14 | |
82b9bde8 | 15 | struct lttng_ust_client_lib_ring_buffer_client_cb { |
b5457df5 | 16 | struct lttng_ust_ring_buffer_client_cb parent; |
b2f3252a | 17 | |
b5457df5 MD |
18 | int (*timestamp_begin) (struct lttng_ust_ring_buffer *buf, |
19 | struct lttng_ust_ring_buffer_channel *chan, | |
b2f3252a | 20 | uint64_t *timestamp_begin); |
b5457df5 MD |
21 | int (*timestamp_end) (struct lttng_ust_ring_buffer *buf, |
22 | struct lttng_ust_ring_buffer_channel *chan, | |
b2f3252a | 23 | uint64_t *timestamp_end); |
b5457df5 MD |
24 | int (*events_discarded) (struct lttng_ust_ring_buffer *buf, |
25 | struct lttng_ust_ring_buffer_channel *chan, | |
b2f3252a | 26 | uint64_t *events_discarded); |
b5457df5 MD |
27 | int (*content_size) (struct lttng_ust_ring_buffer *buf, |
28 | struct lttng_ust_ring_buffer_channel *chan, | |
b2f3252a | 29 | uint64_t *content_size); |
b5457df5 MD |
30 | int (*packet_size) (struct lttng_ust_ring_buffer *buf, |
31 | struct lttng_ust_ring_buffer_channel *chan, | |
b2f3252a | 32 | uint64_t *packet_size); |
b5457df5 MD |
33 | int (*stream_id) (struct lttng_ust_ring_buffer *buf, |
34 | struct lttng_ust_ring_buffer_channel *chan, | |
b2f3252a | 35 | uint64_t *stream_id); |
b5457df5 MD |
36 | int (*current_timestamp) (struct lttng_ust_ring_buffer *buf, |
37 | struct lttng_ust_ring_buffer_channel *chan, | |
fca361e8 | 38 | uint64_t *ts); |
b5457df5 MD |
39 | int (*sequence_number) (struct lttng_ust_ring_buffer *buf, |
40 | struct lttng_ust_ring_buffer_channel *chan, uint64_t *seq); | |
41 | int (*instance_id) (struct lttng_ust_ring_buffer *buf, | |
42 | struct lttng_ust_ring_buffer_channel *chan, uint64_t *id); | |
82b9bde8 JD |
43 | }; |
44 | ||
8cd08025 MJ |
45 | void lttng_ust_ring_buffer_clients_init(void) |
46 | __attribute__((visibility("hidden"))); | |
47 | ||
48 | void lttng_ust_ring_buffer_clients_exit(void) | |
49 | __attribute__((visibility("hidden"))); | |
14e0a135 | 50 | |
1d18d519 MJ |
51 | void lttng_ring_buffer_client_overwrite_init(void) |
52 | __attribute__((visibility("hidden"))); | |
53 | ||
54 | void lttng_ring_buffer_client_overwrite_rt_init(void) | |
55 | __attribute__((visibility("hidden"))); | |
56 | ||
57 | void lttng_ring_buffer_client_discard_init(void) | |
58 | __attribute__((visibility("hidden"))); | |
59 | ||
60 | void lttng_ring_buffer_client_discard_rt_init(void) | |
61 | __attribute__((visibility("hidden"))); | |
62 | ||
63 | void lttng_ring_buffer_metadata_client_init(void) | |
64 | __attribute__((visibility("hidden"))); | |
65 | ||
66 | ||
67 | void lttng_ring_buffer_client_overwrite_exit(void) | |
68 | __attribute__((visibility("hidden"))); | |
69 | ||
70 | void lttng_ring_buffer_client_overwrite_rt_exit(void) | |
71 | __attribute__((visibility("hidden"))); | |
72 | ||
73 | void lttng_ring_buffer_client_discard_exit(void) | |
74 | __attribute__((visibility("hidden"))); | |
75 | ||
76 | void lttng_ring_buffer_client_discard_rt_exit(void) | |
77 | __attribute__((visibility("hidden"))); | |
78 | ||
79 | void lttng_ring_buffer_metadata_client_exit(void) | |
80 | __attribute__((visibility("hidden"))); | |
81 | ||
82 | ||
a9fd951a | 83 | void lttng_ust_ring_buffer_client_overwrite_alloc_tls(void) |
1d18d519 MJ |
84 | __attribute__((visibility("hidden"))); |
85 | ||
a9fd951a | 86 | void lttng_ust_ring_buffer_client_overwrite_rt_alloc_tls(void) |
1d18d519 MJ |
87 | __attribute__((visibility("hidden"))); |
88 | ||
a9fd951a | 89 | void lttng_ust_ring_buffer_client_discard_alloc_tls(void) |
1d18d519 MJ |
90 | __attribute__((visibility("hidden"))); |
91 | ||
a9fd951a | 92 | void lttng_ust_ring_buffer_client_discard_rt_alloc_tls(void) |
1d18d519 | 93 | __attribute__((visibility("hidden"))); |
14e0a135 | 94 | |
8cd08025 | 95 | #endif /* _UST_COMMON_RINGBUFFER_CLIENTS_CLIENTS_H */ |