Cleanup: apply `include-what-you-use` guideline for `uint*_t`
[lttng-ust.git] / libringbuffer / frontend_types.h
index bf4b4185e2368945494dd39e3df86efed5ff1aa8..43300f6a74ddec2324fbfb9f0d0c6dd8bcbb1786 100644 (file)
@@ -28,6 +28,7 @@
  * See ring_buffer_frontend.c for more information on wait-free algorithms.
  */
 
+#include <stdint.h>
 #include <string.h>
 #include <time.h>      /* for timer_t */
 
@@ -70,7 +71,13 @@ struct channel {
        size_t priv_data_offset;
        unsigned int nr_streams;                /* Number of streams */
        struct lttng_ust_shm_handle *handle;
-       char padding[RB_CHANNEL_PADDING];
+       /* Extended options. */
+       union {
+               struct {
+                       int32_t blocking_timeout_ms;
+               } s;
+               char padding[RB_CHANNEL_PADDING];
+       } u;
        /*
         * Associated backend contains a variable-length array. Needs to
         * be last member.
@@ -196,6 +203,20 @@ struct lttng_ust_lib_ring_buffer {
 
        DECLARE_SHMP(struct commit_counters_cold, commit_cold);
                                        /* Commit count per sub-buffer */
+       DECLARE_SHMP(uint64_t, ts_end); /*
+                                        * timestamp_end per sub-buffer.
+                                        * Time is sampled by the
+                                        * switch_*_end() callbacks
+                                        * which are the last space
+                                        * reservation performed in the
+                                        * sub-buffer before it can be
+                                        * fully committed and
+                                        * delivered. This time value is
+                                        * then read by the deliver
+                                        * callback, performed by the
+                                        * last commit before the buffer
+                                        * becomes readable.
+                                        */
        long active_readers;            /*
                                         * Active readers count
                                         * standard atomic access (shared)
This page took 0.024195 seconds and 4 git commands to generate.