git: 301a27dc6546 - main - atomic: Style

From: Mark Johnston <markj_at_FreeBSD.org>
Date: Tue, 11 Oct 2022 22:35:34 UTC
The branch main has been updated by markj:

URL: https://cgit.FreeBSD.org/src/commit/?id=301a27dc65463fc9a909835863ff5566623f6ef2

commit 301a27dc65463fc9a909835863ff5566623f6ef2
Author:     Mark Johnston <markj@FreeBSD.org>
AuthorDate: 2022-10-11 14:54:36 +0000
Commit:     Mark Johnston <markj@FreeBSD.org>
CommitDate: 2022-10-11 22:19:08 +0000

    atomic: Style
    
    Fixes:          30253da1a982 ("atomic: Add some type checking to plain atomic_load/store helpers")
    MFC after:      1 week
---
 sys/sys/atomic_common.h | 20 +++++++++++++-------
 1 file changed, 13 insertions(+), 7 deletions(-)

diff --git a/sys/sys/atomic_common.h b/sys/sys/atomic_common.h
index 04281ae8f2ed..a7b0b50512dc 100644
--- a/sys/sys/atomic_common.h
+++ b/sys/sys/atomic_common.h
@@ -81,15 +81,21 @@
 
 #define	__atomic_load_generic(p, t, ut, n)	\
 	_Generic(*(p),				\
-	    t: __atomic_load_ ## n ## _relaxed(p), ut: __atomic_load_ ## n ## _relaxed(p))
+	    t: __atomic_load_ ## n ## _relaxed(p), \
+	    ut: __atomic_load_ ## n ## _relaxed(p))
 #define	__atomic_store_generic(p, v, t, ut, n)	\
 	_Generic(*(p),				\
-	    t: __atomic_store_ ## n ## _relaxed(p, v), ut: __atomic_store_ ## n ## _relaxed(p, v))
+	    t: __atomic_store_ ## n ## _relaxed(p, v), \
+	    ut: __atomic_store_ ## n ## _relaxed(p, v))
 #else
-#define	atomic_load_bool(p)			__atomic_load_bool_relaxed(p)
-#define	atomic_store_bool(p, v)			__atomic_store_bool_relaxed(p, v)
-#define	__atomic_load_generic(p, t, ut, n)	__atomic_load_ ## n ## _relaxed(p)
-#define	__atomic_store_generic(p, v, t, ut, n)	__atomic_store_ ## n ## _relaxed(p, v)
+#define	atomic_load_bool(p)			\
+	__atomic_load_bool_relaxed(p)
+#define	atomic_store_bool(p, v)			\
+	__atomic_store_bool_relaxed(p, v)
+#define	__atomic_load_generic(p, t, ut, n)	\
+	__atomic_load_ ## n ## _relaxed(p)
+#define	__atomic_store_generic(p, v, t, ut, n)	\
+	__atomic_store_ ## n ## _relaxed(p, v)
 #endif
 
 #define	atomic_load_char(p)	__atomic_load_generic(p, char, u_char, char)
@@ -134,4 +140,4 @@
 
 #define	atomic_interrupt_fence()	__compiler_membar()
 
-#endif
+#endif /* !_SYS_ATOMIC_COMMON_H_ */