| From | Kent Overstreet <> | Subject | [PATCH 01/32] Compiler Attributes: add __flatten | Date | Tue, 9 May 2023 12:56:26 -0400 |
| |
From: Kent Overstreet <kent.overstreet@gmail.com>
This makes __attribute__((flatten)) available, which is used by bcachefs.
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com> Cc: Miguel Ojeda <ojeda@kernel.org> (maintainer:COMPILER ATTRIBUTES) Cc: Nick Desaulniers <ndesaulniers@google.com> (reviewer:COMPILER ATTRIBUTES) Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev> --- include/linux/compiler_attributes.h | 5 +++++ 1 file changed, 5 insertions(+)
diff --git a/include/linux/compiler_attributes.h b/include/linux/compiler_attributes.h index e659cb6fde..e56793bc08 100644 --- a/include/linux/compiler_attributes.h +++ b/include/linux/compiler_attributes.h @@ -366,4 +366,9 @@ */ #define __fix_address noinline __noclone +/* + * gcc: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-flatten-function-attribute + */ +#define __flatten __attribute__((flatten)) + #endif /* __LINUX_COMPILER_ATTRIBUTES_H */ -- 2.40.1
|