From: ebiederm@xmission.com (Eric W. Biederman)
To: Theodore Tso <tytso@mit.edu>
Cc: Ulrich Drepper <drepper@redhat.com>,
Arjan van de Ven <arjan@infradead.org>,
"Randy.Dunlap" <rdunlap@xenotime.net>,
akpm@osdl.org, linux-kernel@vger.kernel.org,
libc-alpha@sourceware.org, Andi Kleen <ak@suse.de>
Subject: Re: [PATCH] Use uname not sysctl to get the kernel revision
Date: Wed, 12 Jul 2006 18:19:19 -0600 [thread overview]
Message-ID: <m1fyh673w8.fsf@ebiederm.dsl.xmission.com> (raw)
In-Reply-To: <20060712232414.GI9040@thunk.org> (Theodore Tso's message of "Wed, 12 Jul 2006 19:24:14 -0400")
Theodore Tso <tytso@mit.edu> writes:
> On Wed, Jul 12, 2006 at 11:42:47AM -0600, Eric W. Biederman wrote:
>> Unless a darn good reason for keeping it is found, sys_sysctl won't be
>> in the kernel several months from now. And uname is faster by a large
>> margin than /proc.
>
> Um, if glibc is using sys_sysctl, then that's a pretty good reason.
> Once we remove it from the kernel, then people will be forced to
> upgrade glibc's before they can install a newer kernel. Can we please
> give people some time for an version of glibc with this change to make
> it out to most deployed systems, first? It's really annoying when
> it's not possible to install a stock kernel.org kernel on a system,
> and often upgrading glibc is not a trivial thing to do on a
> distribution userspace, especially if there is a concern for ISV
> compatibility. (Especially if C++ code is involved, unfortunately.)
I agree.
The reason for stopping this is that sys_sysctl at that location
in glibc is unnecessary, we can use uname now.
Currently that usage by glibc gives false positives if we want
to warn users.
>> Right now because there has been a deprecated note in
>> "include/linux/sysctl.h" since 2003 people currently feel fine with
>> letting sys_sysctl code bit rot. I am trying to resolve that
>> situation most likely by just updating the few stray pieces of user
>> space that care and then cutting out that chunk of kernel code.
>
> What we should do is what we've done in the past before removing a
> system call like this. printk a deprecation warning no more than n
> times an hours with the process name using the deprecated interface.
> A deprecated note in a header isn't necessarily something which will
> be noticed by userspace programmers. Heck, it isn't even in
> Documentation/feature-removal-schedule.txt yet.
I sent Andrew patches yesterday to put it in
Documentation/feature-remove-schedule.txt, and to print a warning, and
to optionally compile out sys_sysctl.
> If people want to remove it, let's please do this in an orderly
> fashion, and with ample warning that people besides kernel developers
> will actually *notice*.
I agree. Part of that beyond the deprecated message is sending
patches to fixup the few remaining users and talking about it a lot
so even if someone doesn't run the kernels with deprecated message
they might notice something.
> - Ted
>
> P.S. I happen to be one those developers who think the binary
> interface is not so bad, and for compared to reading from /proc/sys,
> the sysctl syscall *is* faster. But at the same there, there really
> isn't anything where really does require that kind of speed, so that
> point is moot. But at the same time, what is the cost of leaving
> sys_sysctl in the kernel for an extra 6-12 months, or even longer,
> starting from now?
The core problem is enough people have read that depreciated warning
that the binary interface of kernel/sysctl.c is not being maintained
seriously. So the code must move out of this half deprecated state.
Either to all of the way gone (preferably) or reinstated as an
interface that we are serious about maintaining. Code that
bit rots and people don't care is a problem.
> Or if we going to remove parts of sysctl, can we at least keep enough
> there so that existing glibc systems don't break?
That is not a problem. glibc will happily fall back to reading
the values from /proc/sys/kernel/version if sysctl fails. It
just makes more sense (to me at least) to use uname for
getting uname data.
Eric
next prev parent reply other threads:[~2006-07-13 0:20 UTC|newest]
Thread overview: 47+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-10 22:39 [PATCH] sysctl: Document that sys_sysctl will be removed Eric W. Biederman
2006-07-10 22:50 ` Randy.Dunlap
2006-07-11 4:10 ` Eric W. Biederman
2006-07-11 7:07 ` Arjan van de Ven
2006-07-12 16:25 ` [PATCH] Use uname not sysctl to get the kernel revision Eric W. Biederman
2006-07-12 16:50 ` Ulrich Drepper
2006-07-12 17:42 ` Eric W. Biederman
2006-07-12 23:24 ` Theodore Tso
2006-07-12 23:31 ` Andi Kleen
2006-07-13 0:12 ` Theodore Tso
2006-07-13 2:33 ` Eric W. Biederman
2006-07-13 12:15 ` Andi Kleen
2006-07-12 23:44 ` Steve Munroe
2006-07-14 18:49 ` Benjamin Herrenschmidt
2006-07-14 19:09 ` Andi Kleen
2006-07-13 0:19 ` Eric W. Biederman [this message]
2006-07-12 18:44 ` Roland McGrath
2006-07-12 19:33 ` Ulrich Drepper
2006-07-12 19:53 ` Jakub Jelinek
2006-07-12 20:09 ` H. Peter Anvin
2006-07-12 21:23 ` Eric W. Biederman
2006-07-12 21:29 ` Arjan van de Ven
2006-07-12 21:56 ` Eric W. Biederman
2006-07-12 22:01 ` Arjan van de Ven
2006-07-12 22:02 ` H. Peter Anvin
2006-07-12 22:26 ` Eric W. Biederman
2006-07-12 22:31 ` H. Peter Anvin
2006-07-12 23:07 ` Alan Cox
2006-07-12 23:19 ` H. Peter Anvin
2006-07-13 11:15 ` Alan Cox
2006-07-14 18:45 ` Benjamin Herrenschmidt
2006-07-14 19:11 ` H. Peter Anvin
2006-07-12 21:29 ` H. Peter Anvin
2006-07-12 21:33 ` Michael Tokarev
2006-07-13 5:17 ` Ulrich Drepper
2006-07-13 6:27 ` Ian Wienand
2006-07-13 14:39 ` Eric W. Biederman
2006-07-13 15:05 ` Arjan van de Ven
2006-07-13 5:00 Albert Cahalan
2006-07-13 5:42 ` H. Peter Anvin
2006-07-13 6:09 ` Albert Cahalan
2006-07-13 6:13 ` Albert Cahalan
2006-07-13 6:38 ` Eric W. Biederman
2006-07-13 16:15 ` Albert Cahalan
2006-07-13 16:53 ` Eric W. Biederman
2006-07-13 17:06 ` Albert Cahalan
2006-07-13 15:20 ` Eric W. Biederman
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=m1fyh673w8.fsf@ebiederm.dsl.xmission.com \
--to=ebiederm@xmission.com \
--cc=ak@suse.de \
--cc=akpm@osdl.org \
--cc=arjan@infradead.org \
--cc=drepper@redhat.com \
--cc=libc-alpha@sourceware.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rdunlap@xenotime.net \
--cc=tytso@mit.edu \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®