compiler.h: introduce __section()

Add a new helper: __section() that makes a section definition
much shorter and more readable.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
This commit is contained in:
Sam Ravnborg
2008-01-20 18:54:48 +01:00
parent 01ba2bdc6b
commit f3fe866d59
2 changed files with 18 additions and 13 deletions

View File

@ -175,4 +175,9 @@ extern void __chk_io_ptr(const volatile void __iomem *);
#define __cold
#endif
/* Simple shorthand for a section definition */
#ifndef __section
# define __section(S) __attribute__ ((__section__(#S)))
#endif
#endif /* __LINUX_COMPILER_H */