uint8_t header_end[0]; /* End of header */
};
-static const struct lttng_ust_lib_ring_buffer_config client_config;
+static const struct lttng_ust_ring_buffer_config client_config;
/* No nested use supported for metadata ring buffer. */
-static DEFINE_URCU_TLS(struct lttng_ust_lib_ring_buffer_ctx_private, private_ctx);
+static DEFINE_URCU_TLS(struct lttng_ust_ring_buffer_ctx_private, private_ctx);
static inline uint64_t lib_ring_buffer_clock_read(
- struct lttng_ust_lib_ring_buffer_channel *chan __attribute__((unused)))
+ struct lttng_ust_ring_buffer_channel *chan __attribute__((unused)))
{
return 0;
}
static inline
size_t record_header_size(
- const struct lttng_ust_lib_ring_buffer_config *config __attribute__((unused)),
- struct lttng_ust_lib_ring_buffer_channel *chan __attribute__((unused)),
+ const struct lttng_ust_ring_buffer_config *config __attribute__((unused)),
+ struct lttng_ust_ring_buffer_channel *chan __attribute__((unused)),
size_t offset __attribute__((unused)),
size_t *pre_header_padding __attribute__((unused)),
- struct lttng_ust_lib_ring_buffer_ctx *ctx __attribute__((unused)),
+ struct lttng_ust_ring_buffer_ctx *ctx __attribute__((unused)),
void *client_ctx __attribute__((unused)))
{
return 0;
#include "lttng-rb-clients.h"
static uint64_t client_ring_buffer_clock_read(
- struct lttng_ust_lib_ring_buffer_channel *chan __attribute__((unused)))
+ struct lttng_ust_ring_buffer_channel *chan __attribute__((unused)))
{
return 0;
}
static
size_t client_record_header_size(
- const struct lttng_ust_lib_ring_buffer_config *config __attribute__((unused)),
- struct lttng_ust_lib_ring_buffer_channel *chan __attribute__((unused)),
+ const struct lttng_ust_ring_buffer_config *config __attribute__((unused)),
+ struct lttng_ust_ring_buffer_channel *chan __attribute__((unused)),
size_t offset __attribute__((unused)),
size_t *pre_header_padding __attribute__((unused)),
- struct lttng_ust_lib_ring_buffer_ctx *ctx __attribute__((unused)),
+ struct lttng_ust_ring_buffer_ctx *ctx __attribute__((unused)),
void *client_ctx __attribute__((unused)))
{
return 0;
return offsetof(struct metadata_packet_header, header_end);
}
-static void client_buffer_begin(struct lttng_ust_lib_ring_buffer *buf,
+static void client_buffer_begin(struct lttng_ust_ring_buffer *buf,
uint64_t tsc __attribute__((unused)),
unsigned int subbuf_idx,
struct lttng_ust_shm_handle *handle)
{
- struct lttng_ust_lib_ring_buffer_channel *chan = shmp(handle, buf->backend.chan);
+ struct lttng_ust_ring_buffer_channel *chan = shmp(handle, buf->backend.chan);
struct metadata_packet_header *header =
(struct metadata_packet_header *)
lib_ring_buffer_offset_address(&buf->backend,
* offset is assumed to never be 0 here : never deliver a completely empty
* subbuffer. data_size is between 1 and subbuf_size.
*/
-static void client_buffer_end(struct lttng_ust_lib_ring_buffer *buf,
+static void client_buffer_end(struct lttng_ust_ring_buffer *buf,
uint64_t tsc __attribute__((unused)),
unsigned int subbuf_idx, unsigned long data_size,
struct lttng_ust_shm_handle *handle)
{
- struct lttng_ust_lib_ring_buffer_channel *chan = shmp(handle, buf->backend.chan);
+ struct lttng_ust_ring_buffer_channel *chan = shmp(handle, buf->backend.chan);
struct metadata_packet_header *header =
(struct metadata_packet_header *)
lib_ring_buffer_offset_address(&buf->backend,
}
static int client_buffer_create(
- struct lttng_ust_lib_ring_buffer *buf __attribute__((unused)),
+ struct lttng_ust_ring_buffer *buf __attribute__((unused)),
void *priv __attribute__((unused)),
int cpu __attribute__((unused)),
const char *name __attribute__((unused)),
}
static void client_buffer_finalize(
- struct lttng_ust_lib_ring_buffer *buf __attribute__((unused)),
+ struct lttng_ust_ring_buffer *buf __attribute__((unused)),
void *priv __attribute__((unused)),
int cpu __attribute__((unused)),
struct lttng_ust_shm_handle *handle __attribute__((unused)))
},
};
-static const struct lttng_ust_lib_ring_buffer_config client_config = {
+static const struct lttng_ust_ring_buffer_config client_config = {
.cb.ring_buffer_clock_read = client_ring_buffer_clock_read,
.cb.record_header_size = client_record_header_size,
.cb.subbuffer_header_size = client_packet_header_size,
}
static
-int lttng_event_reserve(struct lttng_ust_lib_ring_buffer_ctx *ctx)
+int lttng_event_reserve(struct lttng_ust_ring_buffer_ctx *ctx)
{
int ret;
- memset(&URCU_TLS(private_ctx), 0, sizeof(struct lttng_ust_lib_ring_buffer_ctx_private));
+ memset(&URCU_TLS(private_ctx), 0, sizeof(struct lttng_ust_ring_buffer_ctx_private));
URCU_TLS(private_ctx).pub = ctx;
URCU_TLS(private_ctx).chan = ctx->client_priv;
ctx->priv = &URCU_TLS(private_ctx);
}
static
-void lttng_event_commit(struct lttng_ust_lib_ring_buffer_ctx *ctx)
+void lttng_event_commit(struct lttng_ust_ring_buffer_ctx *ctx)
{
lib_ring_buffer_commit(&client_config, ctx);
}
static
-void lttng_event_write(struct lttng_ust_lib_ring_buffer_ctx *ctx,
+void lttng_event_write(struct lttng_ust_ring_buffer_ctx *ctx,
const void *src, size_t len, size_t alignment)
{
- lttng_ust_lib_ring_buffer_align_ctx(ctx, alignment);
+ lttng_ust_ring_buffer_align_ctx(ctx, alignment);
lib_ring_buffer_write(&client_config, ctx, src, len);
}
static
size_t lttng_packet_avail_size(struct lttng_ust_channel_buffer *chan)
{
- struct lttng_ust_lib_ring_buffer_channel *rb_chan = chan->priv->rb_chan;
+ struct lttng_ust_ring_buffer_channel *rb_chan = chan->priv->rb_chan;
unsigned long o_begin;
- struct lttng_ust_lib_ring_buffer *buf;
+ struct lttng_ust_ring_buffer *buf;
buf = shmp(rb_chan->handle, rb_chan->backend.buf[0].shmp); /* Only for global buffer ! */
o_begin = v_read(&client_config, &buf->offset);
static
int lttng_is_finalized(struct lttng_ust_channel_buffer *chan)
{
- struct lttng_ust_lib_ring_buffer_channel *rb_chan = chan->priv->rb_chan;
+ struct lttng_ust_ring_buffer_channel *rb_chan = chan->priv->rb_chan;
return lib_ring_buffer_channel_is_finalized(rb_chan);
}
static
int lttng_is_disabled(struct lttng_ust_channel_buffer *chan)
{
- struct lttng_ust_lib_ring_buffer_channel *rb_chan = chan->priv->rb_chan;
+ struct lttng_ust_ring_buffer_channel *rb_chan = chan->priv->rb_chan;
return lib_ring_buffer_channel_is_disabled(rb_chan);
}
static
int lttng_flush_buffer(struct lttng_ust_channel_buffer *chan)
{
- struct lttng_ust_lib_ring_buffer_channel *rb_chan = chan->priv->rb_chan;
- struct lttng_ust_lib_ring_buffer *buf;
+ struct lttng_ust_ring_buffer_channel *rb_chan = chan->priv->rb_chan;
+ struct lttng_ust_ring_buffer *buf;
int shm_fd, wait_fd, wakeup_fd;
uint64_t memory_map_size;