summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2018-12-27 11:08:31 -0500
committerKent Overstreet <kent.overstreet@linux.dev>2022-10-03 17:01:17 -0400
commitccbc4e1a399470ef18741c6f97d963ea8fef45b0 (patch)
treecd9ef3c55999c2020fb418c8648669b75811e42f
parent4fe89d07dcc2804c8b562f6c7896a45643d34b2f (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 445e80517cab..57e7d0b94119 100644
--- a/include/linux/compiler_attributes.h
+++ b/include/linux/compiler_attributes.h
@@ -371,4 +371,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 */