diff options
author | Arnaud Lacombe <lacombar@gmail.com> | 2011-07-25 20:13:03 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-25 23:57:14 -0400 |
commit | b9d4f426689765d1e066913f6872c8d59e0f2ac9 (patch) | |
tree | aa9f8793febf41a2f913efdb5b16048b960a155b /include/linux/kernel.h | |
parent | 9d00f92f437f0ff682876cab9f2d94cf3b6e5d17 (diff) |
include/linux/kernel.h: hide internal macros from userspace
Unexpose to userland the following macros
- __FUNCTION__
- NUMA_BUILD
- COMPACTION_BUILD
- REBUILD_DUE_TO_FTRACE_MCOUNT_RECORD
Signed-off-by: Arnaud Lacombe <lacombar@gmail.com>
Cc: Rusty Russell <rusty@rustcorp.com.au>
Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: Christoph Lameter <cl@linux.com>
Cc: Mel Gorman <mgorman@suse.de>
Cc: Steven Rostedt <rostedt@goodmis.org>
Acked-by: WANG Cong <xiyou.wangcong@gmail.com>
Cc: Michal Marek <mmarek@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/kernel.h')
-rw-r--r-- | include/linux/kernel.h | 43 |
1 files changed, 21 insertions, 22 deletions
diff --git a/include/linux/kernel.h b/include/linux/kernel.h index bf66f068368b..9a43ad792cfc 100644 --- a/include/linux/kernel.h +++ b/include/linux/kernel.h | |||
@@ -691,6 +691,27 @@ extern int __build_bug_on_failed; | |||
691 | #endif | 691 | #endif |
692 | #endif /* __CHECKER__ */ | 692 | #endif /* __CHECKER__ */ |
693 | 693 | ||
694 | /* Trap pasters of __FUNCTION__ at compile-time */ | ||
695 | #define __FUNCTION__ (__func__) | ||
696 | |||
697 | /* This helps us to avoid #ifdef CONFIG_NUMA */ | ||
698 | #ifdef CONFIG_NUMA | ||
699 | #define NUMA_BUILD 1 | ||
700 | #else | ||
701 | #define NUMA_BUILD 0 | ||
702 | #endif | ||
703 | |||
704 | /* This helps us avoid #ifdef CONFIG_COMPACTION */ | ||
705 | #ifdef CONFIG_COMPACTION | ||
706 | #define COMPACTION_BUILD 1 | ||
707 | #else | ||
708 | #define COMPACTION_BUILD 0 | ||
709 | #endif | ||
710 | |||
711 | /* Rebuild everything on CONFIG_FTRACE_MCOUNT_RECORD */ | ||
712 | #ifdef CONFIG_FTRACE_MCOUNT_RECORD | ||
713 | # define REBUILD_DUE_TO_FTRACE_MCOUNT_RECORD | ||
714 | #endif | ||
694 | 715 | ||
695 | struct sysinfo; | 716 | struct sysinfo; |
696 | extern int do_sysinfo(struct sysinfo *info); | 717 | extern int do_sysinfo(struct sysinfo *info); |
@@ -715,26 +736,4 @@ struct sysinfo { | |||
715 | char _f[20-2*sizeof(long)-sizeof(int)]; /* Padding: libc5 uses this.. */ | 736 | char _f[20-2*sizeof(long)-sizeof(int)]; /* Padding: libc5 uses this.. */ |
716 | }; | 737 | }; |
717 | 738 | ||
718 | /* Trap pasters of __FUNCTION__ at compile-time */ | ||
719 | #define __FUNCTION__ (__func__) | ||
720 | |||
721 | /* This helps us to avoid #ifdef CONFIG_NUMA */ | ||
722 | #ifdef CONFIG_NUMA | ||
723 | #define NUMA_BUILD 1 | ||
724 | #else | ||
725 | #define NUMA_BUILD 0 | ||
726 | #endif | ||
727 | |||
728 | /* This helps us avoid #ifdef CONFIG_COMPACTION */ | ||
729 | #ifdef CONFIG_COMPACTION | ||
730 | #define COMPACTION_BUILD 1 | ||
731 | #else | ||
732 | #define COMPACTION_BUILD 0 | ||
733 | #endif | ||
734 | |||
735 | /* Rebuild everything on CONFIG_FTRACE_MCOUNT_RECORD */ | ||
736 | #ifdef CONFIG_FTRACE_MCOUNT_RECORD | ||
737 | # define REBUILD_DUE_TO_FTRACE_MCOUNT_RECORD | ||
738 | #endif | ||
739 | |||
740 | #endif | 739 | #endif |