consumer: introduce channel lock
[lttng-tools.git] / src / common / consumer.h
index a5a758be5ea141ff609051463852be49525d6b1b..8751f234e31605188294c809d9fef593a82d8198 100644 (file)
@@ -157,6 +157,15 @@ struct lttng_consumer_channel {
        /* On-disk circular buffer */
        uint64_t tracefile_size;
        uint64_t tracefile_count;
+       /*
+        * Channel lock.
+        *
+        * This is nested INSIDE the consumer data lock.
+        * This is nested OUTSIDE the metadata cache lock.
+        * This is nested OUTSIDE stream lock.
+        * This is nested OUTSIDE consumer_relayd_sock_pair lock.
+        */
+       pthread_mutex_t lock;
 };
 
 /*
@@ -228,6 +237,7 @@ struct lttng_consumer_stream {
         *
         * This is nested INSIDE the consumer_data lock.
         * This is nested INSIDE the metadata cache lock.
+        * This is nested INSIDE the channel lock.
         * This is nested OUTSIDE consumer_relayd_sock_pair lock.
         */
        pthread_mutex_t lock;
This page took 0.022802 seconds and 4 git commands to generate.