public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] SYSCTL: Fix sysctl breakage on systems with older glibc
@ 2009-12-16 11:28 Andi Kleen
  2009-12-17 15:07 ` Eric W. Biederman
  0 siblings, 1 reply; 5+ messages in thread
From: Andi Kleen @ 2009-12-16 11:28 UTC (permalink / raw)
  To: ebiederm, akpm, torvalds, linux-kernel

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 s ystem 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>

diff -u linux-2.6.32-git12/kernel/sysctl_binary.c-o linux-2.6.32-git12/kernel/sysctl_binary.c
--- linux-2.6.32-git12/kernel/sysctl_binary.c-o	2009-12-16 12:15:52.000000000 +0100
+++ linux-2.6.32-git12/kernel/sysctl_binary.c	2009-12-16 12:14:58.000000000 +0100
@@ -1399,6 +1399,13 @@
 {
 	int i;
 
+	/* 
+	 * CTL_KERN/KERN_VERSION is used by older glibc and cannot 
+	 * ever go away.
+	 */
+	if (name[0] == CTL_KERN && name[1] == KERN_VERSION)
+		return;
+
 	if (printk_ratelimit()) {
 		printk(KERN_INFO
 			"warning: process `%s' used the deprecated sysctl "

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-12-17 21:16 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-16 11:28 [PATCH] SYSCTL: Fix sysctl breakage on systems with older glibc Andi Kleen
2009-12-17 15:07 ` Eric W. Biederman
2009-12-17 16:46   ` Andi Kleen
2009-12-17 18:30     ` Eric W. Biederman
2009-12-17 21:16       ` Linus Torvalds

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox