X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=src%2Fcommon%2Fringbuffer%2Fring_buffer_frontend.c;h=4d06bf63140c6218c8abf7b278cd3f7b48026194;hb=434897eecad53ba1c16b8f7881d18ba187a49163;hp=d6f5365c8eb1e3629d4a4c829414d13bb00ea8da;hpb=74cc1f594e05b5a3524529f018d85efaad53f9a3;p=lttng-ust.git diff --git a/src/common/ringbuffer/ring_buffer_frontend.c b/src/common/ringbuffer/ring_buffer_frontend.c index d6f5365c..4d06bf63 100644 --- a/src/common/ringbuffer/ring_buffer_frontend.c +++ b/src/common/ringbuffer/ring_buffer_frontend.c @@ -78,6 +78,8 @@ /* * Non-static to ensure the compiler does not optimize away the xor. */ +uint8_t lttng_crash_magic_xor[] + __attribute__((visibility("hidden"))); uint8_t lttng_crash_magic_xor[] = RB_CRASH_DUMP_ABI_MAGIC_XOR; /* @@ -1180,7 +1182,8 @@ struct lttng_ust_ring_buffer *channel_get_ring_buffer( struct lttng_ust_shm_handle *handle, int *shm_fd, int *wait_fd, int *wakeup_fd, - uint64_t *memory_map_size) + uint64_t *memory_map_size, + void **memory_map_addr) { struct shm_ref *ref; @@ -1196,6 +1199,7 @@ struct lttng_ust_ring_buffer *channel_get_ring_buffer( *wakeup_fd = shm_get_wakeup_fd(handle, ref); if (shm_get_shm_size(handle, ref, memory_map_size)) return NULL; + *memory_map_addr = handle->table->objects[ref->index].memory_map; return shmp(handle, chan->backend.buf[cpu].shmp); } @@ -2556,9 +2560,9 @@ void lib_ring_buffer_check_deliver_slow(const struct lttng_ust_ring_buffer_confi } /* - * Force a read (imply TLS fixup for dlopen) of TLS variables. + * Force a read (imply TLS allocation for dlopen) of TLS variables. */ -void lttng_fixup_ringbuffer_tls(void) +void lttng_ringbuffer_alloc_tls(void) { asm volatile ("" : : "m" (URCU_TLS(lib_ring_buffer_nesting))); }