diff mbox

[v4,5/6] tools: add __section() to compiler.h

Message ID 20170115211215.17216-6-mcgrof@kernel.org (mailing list archive)
State New, archived
Headers show

Commit Message

Luis Chamberlain Jan. 15, 2017, 9:12 p.m. UTC
This will be used later by the userspace linker table.

Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org>
---
 tools/include/linux/compiler.h | 2 ++
 1 file changed, 2 insertions(+)

Comments

Greg Kroah-Hartman Jan. 19, 2017, 11:04 a.m. UTC | #1
On Sun, Jan 15, 2017 at 01:12:14PM -0800, Luis R. Rodriguez wrote:
> This will be used later by the userspace linker table.

same comment as the last time you used this sentence as a changelog
text...

thanks,

greg k-h
diff mbox

Patch

diff --git a/tools/include/linux/compiler.h b/tools/include/linux/compiler.h
index 556c991de212..6321265df00a 100644
--- a/tools/include/linux/compiler.h
+++ b/tools/include/linux/compiler.h
@@ -132,4 +132,6 @@  static __always_inline void __write_once_size(volatile void *p, void *res, int s
 #define WRITE_ONCE(x, val) \
 	({ union { typeof(x) __val; char __c[1]; } __u = { .__val = (val) }; __write_once_size(&(x), __u.__c, sizeof(x)); __u.__val; })
 
+#define __section(S)	__attribute__ ((__section__(#S)))
+
 #endif /* _TOOLS_LINUX_COMPILER_H */