diff options
author | Dag-Erling Smørgrav <des@linpro.no> | 2006-01-02 09:57:06 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-02 11:38:38 -0500 |
commit | abe842eb98c45e2b77c5868ef106616ca828a3e4 (patch) | |
tree | f0d89e7d946a7ed9b57bb29e93bae4ce25d2cbc2 | |
parent | f12f4d90308a22396ac87f6c3a7b2620589614c3 (diff) |
[PATCH] Avoid namespace pollution in <asm/param.h>
In commit 3D59121003721a8fad11ee72e646fd9d3076b5679c, the x86 and x86-64
<asm/param.h> was changed to include <linux/config.h> for the
configurable timer frequency.
However, asm/param.h is sometimes used in userland (it is included
indirectly from <sys/param.h>), so your commit pollutes the userland
namespace with tons of CONFIG_FOO macros. This greatly confuses
software packages (such as BusyBox) which use CONFIG_FOO macros
themselves to control the inclusion of optional features.
After a short exchange, Christoph approved this patch
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r-- | include/asm-i386/param.h | 3 | ||||
-rw-r--r-- | include/asm-x86_64/param.h | 3 |
2 files changed, 2 insertions, 4 deletions
diff --git a/include/asm-i386/param.h b/include/asm-i386/param.h index fa02e67ea86b..095580f3a45c 100644 --- a/include/asm-i386/param.h +++ b/include/asm-i386/param.h | |||
@@ -1,9 +1,8 @@ | |||
1 | #include <linux/config.h> | ||
2 | |||
3 | #ifndef _ASMi386_PARAM_H | 1 | #ifndef _ASMi386_PARAM_H |
4 | #define _ASMi386_PARAM_H | 2 | #define _ASMi386_PARAM_H |
5 | 3 | ||
6 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | # include <linux/config.h> | ||
7 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ | 6 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ |
8 | # define USER_HZ 100 /* .. some user interfaces are in "ticks" */ | 7 | # define USER_HZ 100 /* .. some user interfaces are in "ticks" */ |
9 | # define CLOCKS_PER_SEC (USER_HZ) /* like times() */ | 8 | # define CLOCKS_PER_SEC (USER_HZ) /* like times() */ |
diff --git a/include/asm-x86_64/param.h b/include/asm-x86_64/param.h index 40b11937180d..5956b23b57c2 100644 --- a/include/asm-x86_64/param.h +++ b/include/asm-x86_64/param.h | |||
@@ -1,9 +1,8 @@ | |||
1 | #include <linux/config.h> | ||
2 | |||
3 | #ifndef _ASMx86_64_PARAM_H | 1 | #ifndef _ASMx86_64_PARAM_H |
4 | #define _ASMx86_64_PARAM_H | 2 | #define _ASMx86_64_PARAM_H |
5 | 3 | ||
6 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | # include <linux/config.h> | ||
7 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ | 6 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ |
8 | # define USER_HZ 100 /* .. some user interfaces are in "ticks */ | 7 | # define USER_HZ 100 /* .. some user interfaces are in "ticks */ |
9 | #define CLOCKS_PER_SEC (USER_HZ) /* like times() */ | 8 | #define CLOCKS_PER_SEC (USER_HZ) /* like times() */ |