summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2018-12-27 11:08:31 -0500
committerKent Overstreet <kent.overstreet@gmail.com>2020-08-13 17:35:48 -0400
commitce486f26541bbdff445d2135e0821e3936794a0c (patch)
treef0dca4871abc4b1001363d0cfdd227f865c98185
parentbcf876870b95592b52519ed4aafcf9d95999bc9c (diff)
Compiler Attributes: add __flatten
Prep work for bcachefs Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
-rw-r--r--include/linux/compiler_attributes.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/compiler_attributes.h b/include/linux/compiler_attributes.h
index c8f03d2969df..6165f4f769b6 100644
--- a/include/linux/compiler_attributes.h
+++ b/include/linux/compiler_attributes.h
@@ -271,4 +271,9 @@
*/
#define __weak __attribute__((__weak__))
+/*
+ * gcc: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-flatten-function-attribute
+ */
+#define __flatten __attribute__((flatten))
+
#endif /* __LINUX_COMPILER_ATTRIBUTES_H */