Fix: pass private data to context callbacks
[lttng-ust.git] / libringbuffer / vatomic.h
index 29bb67d7cc0f405ca579dc74898381e1e61c450c..199d2c77faacc184856ba8317ba829913c3f091a 100644 (file)
@@ -1,21 +1,12 @@
-#ifndef _LINUX_RING_BUFFER_VATOMIC_H
-#define _LINUX_RING_BUFFER_VATOMIC_H
-
 /*
- * linux/ringbuffer/vatomic.h
- *
- * Copyright (C) 2010 - Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
+ * SPDX-License-Identifier: MIT
  *
- * THIS MATERIAL IS PROVIDED AS IS, WITH ABSOLUTELY NO WARRANTY EXPRESSED
- * OR IMPLIED.  ANY USE IS AT YOUR OWN RISK.
- *
- * Permission is hereby granted to use or copy this program
- * for any purpose,  provided the above notices are retained on all copies.
- * Permission to modify the code and to distribute modified code is granted,
- * provided the above notices are retained, and a notice that the code was
- * modified is included with the above copyright notice.
+ * Copyright (C) 2010-2012 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
  */
 
+#ifndef _LTTNG_RING_BUFFER_VATOMIC_H
+#define _LTTNG_RING_BUFFER_VATOMIC_H
+
 #include <assert.h>
 #include <urcu/uatomic.h>
 
@@ -65,7 +56,7 @@ void v_inc(const struct lttng_ust_lib_ring_buffer_config *config, union v_atomic
  * Non-atomic decrement. Only used by reader, apply to reader-owned subbuffer.
  */
 static inline
-void _v_dec(const struct lttng_ust_lib_ring_buffer_config *config, union v_atomic *v_a)
+void _v_dec(const struct lttng_ust_lib_ring_buffer_config *config __attribute__((unused)), union v_atomic *v_a)
 {
        --v_a->v;
 }
@@ -78,4 +69,4 @@ long v_cmpxchg(const struct lttng_ust_lib_ring_buffer_config *config, union v_at
        return uatomic_cmpxchg(&v_a->a, old, _new);
 }
 
-#endif /* _LINUX_RING_BUFFER_VATOMIC_H */
+#endif /* _LTTNG_RING_BUFFER_VATOMIC_H */
This page took 0.024076 seconds and 4 git commands to generate.