Tests: Fix abi conflict test when building with clang
[lttng-ust.git] / src / common / ringbuffer-clients / metadata-template.h
index c6d92936fa3864c13b532aa903cd63b7d4960b86..080288d5241ccb2c60a47d4e2601150de0af4b34 100644 (file)
@@ -93,7 +93,7 @@ static size_t client_packet_header_size(void)
 }
 
 static void client_buffer_begin(struct lttng_ust_ring_buffer *buf,
-               uint64_t tsc __attribute__((unused)),
+               uint64_t timestamp __attribute__((unused)),
                unsigned int subbuf_idx,
                struct lttng_ust_shm_handle *handle)
 {
@@ -125,9 +125,10 @@ static void client_buffer_begin(struct lttng_ust_ring_buffer *buf,
  * subbuffer. data_size is between 1 and subbuf_size.
  */
 static void client_buffer_end(struct lttng_ust_ring_buffer *buf,
-               uint64_t tsc  __attribute__((unused)),
+               uint64_t timestamp  __attribute__((unused)),
                unsigned int subbuf_idx, unsigned long data_size,
-               struct lttng_ust_shm_handle *handle)
+               struct lttng_ust_shm_handle *handle,
+               const struct lttng_ust_ring_buffer_ctx *ctx)
 {
        struct lttng_ust_ring_buffer_channel *chan = shmp(handle, buf->backend.chan);
        struct metadata_packet_header *header =
@@ -146,9 +147,9 @@ static void client_buffer_end(struct lttng_ust_ring_buffer *buf,
         * We do not care about the records lost count, because the metadata
         * channel waits and retry.
         */
-       (void) lib_ring_buffer_get_records_lost_full(&client_config, buf);
-       records_lost += lib_ring_buffer_get_records_lost_wrap(&client_config, buf);
-       records_lost += lib_ring_buffer_get_records_lost_big(&client_config, buf);
+       (void) lib_ring_buffer_get_records_lost_full(&client_config, ctx);
+       records_lost += lib_ring_buffer_get_records_lost_wrap(&client_config, ctx);
+       records_lost += lib_ring_buffer_get_records_lost_big(&client_config, ctx);
        WARN_ON_ONCE(records_lost != 0);
 }
 
@@ -192,7 +193,7 @@ static const struct lttng_ust_ring_buffer_config client_config = {
        .cb.buffer_create = client_buffer_create,
        .cb.buffer_finalize = client_buffer_finalize,
 
-       .tsc_bits = 0,
+       .timestamp_bits = 0,
        .alloc = RING_BUFFER_ALLOC_GLOBAL,
        .sync = RING_BUFFER_SYNC_GLOBAL,
        .mode = RING_BUFFER_MODE_TEMPLATE,
@@ -327,10 +328,11 @@ int lttng_flush_buffer(struct lttng_ust_channel_buffer *chan)
        struct lttng_ust_ring_buffer *buf;
        int shm_fd, wait_fd, wakeup_fd;
        uint64_t memory_map_size;
+       void *memory_map_addr;
 
        buf = channel_get_ring_buffer(&client_config, rb_chan,
                        0, rb_chan->handle, &shm_fd, &wait_fd, &wakeup_fd,
-                       &memory_map_size);
+                       &memory_map_size, &memory_map_addr);
        lib_ring_buffer_switch(&client_config, buf,
                        SWITCH_ACTIVE, rb_chan->handle);
        return 0;
This page took 0.032786 seconds and 4 git commands to generate.