[lkml]   [2005]   [Dec]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: Golden rule: don't break userland (was Re: RFC: Starting a stable kernel series off the 2.6 kernel)
On Sat, Dec 03, 2005 at 01:43:48PM -0500, Jeff Garzik wrote:
> Userland isn't the same. IMO sysfs hackers have forgotten this.

No we have not.

> Anytime you change or remove sysfs attributes these days, you have the
> potential to break userland, which breaks one of the grand axioms of
> Linux. Everybody knows "the rules" when it comes to removing system
> calls, but forgets/ignores them when it comes to ioctls, sysfs
> attributes, and the like.

The _main_ reason of making sysfs contain "one value per file" was to
help mitigate the problems that proc has had in the past where file
format changes broke userspace programs.

Programs that rely on sysfs need to be able to safely handle the fact
that some attributes might or might not be there.

Now to be fair, yes, udev has had big problems with this in the past,
and kernel updates have broken udev. But that was because the bug was
MY fault in udev, not in the kernel. I'll take full responsibility for

And in the future, the driver/class model changes we are going to be
doing (see for more details on this),
will be going to great lengths to prevent anything in userspace from

So, to change your wording a bit, users of sysfs have forgotten how to
program defensively to handle changes that might happen in the future.
I know I'm guilty of this, and am working hard to not make the same
mistakes in the future.


greg "still trying to delete devfs after 1 and 1/2 years notice" k-h
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-12-03 21:38    [W:0.159 / U:3.380 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site