diff options
author | Andi Kleen <andi@firstfloor.org> | 2009-12-16 06:28:44 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-12-16 15:36:18 -0500 |
commit | 61cf693159d6a968a7014e24905143f71ed8ddcf (patch) | |
tree | 595a4bddf8b005f7345cc123b19f4da1f5d07aa7 /kernel/sysctl_binary.c | |
parent | 288f02bbb6e9609cbaf1eb7a9cb97ae45ce090b2 (diff) |
[sysctl] Fix breakage on systems with older glibc
As predicted during code review, the sysctl(2) changes made systems with
old glibc nearly unusable. About every command gives a:
warning: process `ls' used the deprecated sysctl system call with 1.4
warning in the log.
I see this on a SUSE 10.0 system with glibc 2.3.5.
Don't warn for this common case.
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/sysctl_binary.c')
-rw-r--r-- | kernel/sysctl_binary.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/kernel/sysctl_binary.c b/kernel/sysctl_binary.c index b75dbf40f573..112533d5fc08 100644 --- a/kernel/sysctl_binary.c +++ b/kernel/sysctl_binary.c | |||
@@ -1399,6 +1399,13 @@ static void deprecated_sysctl_warning(const int *name, int nlen) | |||
1399 | { | 1399 | { |
1400 | int i; | 1400 | int i; |
1401 | 1401 | ||
1402 | /* | ||
1403 | * CTL_KERN/KERN_VERSION is used by older glibc and cannot | ||
1404 | * ever go away. | ||
1405 | */ | ||
1406 | if (name[0] == CTL_KERN && name[1] == KERN_VERSION) | ||
1407 | return; | ||
1408 | |||
1402 | if (printk_ratelimit()) { | 1409 | if (printk_ratelimit()) { |
1403 | printk(KERN_INFO | 1410 | printk(KERN_INFO |
1404 | "warning: process `%s' used the deprecated sysctl " | 1411 | "warning: process `%s' used the deprecated sysctl " |