Re: /sys/block vs. /sys/class/block

From: Greg KH (greg_at_kroah.com)
Date: 12/22/04

  • Next message: Greg KH: "Re: My vision of usbmon"
    Date:	Tue, 21 Dec 2004 22:20:57 -0800
    To: Stephen Rothwell <sfr@canb.auug.org.au>
    
    

    On Wed, Dec 22, 2004 at 03:34:49PM +1100, Stephen Rothwell wrote:
    > On Tue, 21 Dec 2004 08:07:50 +0100 Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote:
    > >
    > > > Because /sys/block happened before /sys/class did. Al Viro converted
    > > > the block layer before I got the struct class stuff working properly
    > > > during 2.5.
    > > >
    > > > And yes, I would like to convert the block layer to use the class stuff,
    > > > but for right now, I can't as class devices don't allow
    > > > sub-classes-devices, and getting to that work is _way_ down on my list
    > > > of things to do.
    > >
    > > but can't we at least artificially move it down to /sys/class anyway for
    > > the sake of a sane userland API ?
    >
    > Can I then make the obvious suggestion: add a symlink in /sys/class
    > linking to /sys/block and then reverse the symink once the above work has
    > been done and /sys/class/block has been created?
    >
    > Or is that too gross? :-)

    It is gross.

    But I guess I should ask, who really cares about this, so late in the
    sysfs structure game? Is /sys/block/ really a big problem for anyone?
    And if it is, I'd much rather someone make the required driver core
    changes to fix this up properly, than just put a symlink to paper over
    some userspace issue.

    And as Dan said, libsysfs already handles /sys/block just like any other
    class structure, so a "sane" userland API already exists that fixes this
    issue for you.

    thanks,

    greg k-h
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/


  • Next message: Greg KH: "Re: My vision of usbmon"