#include <linux/types.h>
#include <wrapper/vmalloc.h> /* for wrapper_vmalloc_sync_mappings() */
#include <lttng/events.h>
+#include <lttng/events-internal.h>
#include <lttng/tracer.h>
static struct lttng_transport lttng_relay_transport;
static
struct channel *_channel_create(const char *name,
- struct lttng_channel *lttng_chan, void *buf_addr,
+ void *priv, void *buf_addr,
size_t subbuf_size, size_t num_subbuf,
unsigned int switch_timer_interval,
unsigned int read_timer_interval)
{
+ struct lttng_channel *lttng_chan = priv;
struct channel *chan;
chan = channel_create(&client_config, name,
}
static
-int lttng_event_reserve(struct lib_ring_buffer_ctx *ctx, uint32_t event_id)
+int lttng_event_reserve(struct lib_ring_buffer_ctx *ctx)
{
+ struct channel *chan = ctx->client_priv;
int ret;
+ memset(&ctx->priv, 0, sizeof(ctx->priv));
+ ctx->priv.chan = chan;
+
ret = lib_ring_buffer_reserve(&client_config, ctx, NULL);
if (ret)
return ret;
lib_ring_buffer_backend_get_pages(&client_config, ctx,
- &ctx->backend_pages);
+ &ctx->priv.backend_pages);
return 0;
}