All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andi Kleen <andi@firstfloor.org>
To: ebiederm@xmission.com, akpm@linux-foundation.org,
	torvalds@linux-foundation.org, linux-kernel@vger.kernel.org
Subject: [PATCH] SYSCTL: Fix sysctl breakage on systems with older glibc
Date: Wed, 16 Dec 2009 12:28:44 +0100	[thread overview]
Message-ID: <20091216112844.GA31705@basil.fritz.box> (raw)

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 "

             reply	other threads:[~2009-12-16 11:28 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-16 11:28 Andi Kleen [this message]
2009-12-17 15:07 ` [PATCH] SYSCTL: Fix sysctl breakage on systems with older glibc 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

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20091216112844.GA31705@basil.fritz.box \
    --to=andi@firstfloor.org \
    --cc=akpm@linux-foundation.org \
    --cc=ebiederm@xmission.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.