]> git.sesse.net Git - bcachefs-tools-debian/blobdiff - libbcachefs/fifo.h
Update bcachefs sources to b9bd69421f73 bcachefs: x-macro-ify inode flags enum
[bcachefs-tools-debian] / libbcachefs / fifo.h
index 0982af022ff9e07c5123bda6292cc8d1164f56d5..66b945be10c2309a9e758b228b146047b20674e2 100644 (file)
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
 #ifndef _BCACHEFS_FIFO_H
 #define _BCACHEFS_FIFO_H
 
@@ -64,7 +65,7 @@ do {                                                                  \
           (((p) - (fifo)->data)))
 
 #define fifo_entry_idx(fifo, p)        (((p) - &fifo_peek_front(fifo)) & (fifo)->mask)
-#define fifo_idx_entry(fifo, i)        (fifo)->data[((fifo)->front + (i)) & (fifo)->mask]
+#define fifo_idx_entry(fifo, i)        ((fifo)->data[((fifo)->front + (i)) & (fifo)->mask])
 
 #define fifo_push_back_ref(f)                                          \
        (fifo_full((f)) ? NULL : &(f)->data[(f)->back++ & (f)->mask])