X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;ds=sidebyside;f=libringbuffer%2Fbackend_types.h;h=3d8bd3cb3392c1f5c3db2d3fc11323e1b29f7081;hb=d51652f7ee9f3214b62c17441913168115ab4c9e;hp=a77c4c9559a3dd7ef998736a46d1b0d13243c969;hpb=4cfec15c93af7e0cfe3ce769ee90486bb8ab7c37;p=lttng-ust.git diff --git a/libringbuffer/backend_types.h b/libringbuffer/backend_types.h index a77c4c95..3d8bd3cb 100644 --- a/libringbuffer/backend_types.h +++ b/libringbuffer/backend_types.h @@ -11,7 +11,9 @@ * Dual LGPL v2.1/GPL v2 license. */ +#include #include "shm_internal.h" +#include "vatomic.h" struct lttng_ust_lib_ring_buffer_backend_pages { unsigned long mmap_offset; /* offset of the subbuffer in mmap */ @@ -51,7 +53,7 @@ struct lttng_ust_lib_ring_buffer_backend { DECLARE_SHMP(struct channel, chan); /* Associated channel */ int cpu; /* This buffer's cpu. -1 if global. */ union v_atomic records_read; /* Number of records read */ - unsigned int allocated:1; /* Bool: is buffer allocated ? */ + unsigned int allocated:1; /* is buffer allocated ? */ }; struct lttng_ust_lib_ring_buffer_shmp { @@ -67,10 +69,10 @@ struct channel_backend { * for writer. */ unsigned int buf_size_order; /* Order of buffer size */ - int extra_reader_sb:1; /* Bool: has extra reader subbuffer */ + unsigned int extra_reader_sb:1; /* has extra reader subbuffer ? */ unsigned long num_subbuf; /* Number of sub-buffers for writer */ - u64 start_tsc; /* Channel creation TSC value */ - void *priv; /* Client-specific information */ + uint64_t start_tsc; /* Channel creation TSC value */ + DECLARE_SHMP(void *, priv_data);/* Client-specific information */ struct lttng_ust_lib_ring_buffer_config config; /* Ring buffer configuration */ char name[NAME_MAX]; /* Channel name */ struct lttng_ust_lib_ring_buffer_shmp buf[];