13 Oct, 2007

6 commits


12 Jul, 2007

2 commits

  • devt_attr and uevent_attr are either allocated dynamically with or
    embedded in device and class_device as they needed their owner field
    set to the module implementing the driver. Now that sysfs implements
    immediate disconnect and owner field removed from struct attribute,
    there is no reason to do this. Remove these attributes from
    [class_]device and use static attribute structures instead.

    Signed-off-by: Tejun Heo
    Signed-off-by: Greg Kroah-Hartman

    Tejun Heo
     
  • sysfs is now completely out of driver/module lifetime game. After
    deletion, a sysfs node doesn't access anything outside sysfs proper,
    so there's no reason to hold onto the attribute owners. Note that
    often the wrong modules were accounted for as owners leading to
    accessing removed modules.

    This patch kills now unnecessary attribute->owner. Note that with
    this change, userland holding a sysfs node does not prevent the
    backing module from being unloaded.

    For more info regarding lifetime rule cleanup, please read the
    following message.

    http://article.gmane.org/gmane.linux.kernel/510293

    (tweaked by Greg to not delete the field just yet, to make it easier to
    merge things properly.)

    Signed-off-by: Tejun Heo
    Cc: Cornelia Huck
    Cc: Andrew Morton
    Signed-off-by: Greg Kroah-Hartman

    Tejun Heo
     

09 Jun, 2007

1 commit


03 May, 2007

1 commit


28 Apr, 2007

1 commit

  • - uses a kset in "struct class" to keep track of all directories
    belonging to this class
    - merges with the /sys/devices/virtual logic.
    - removes the namespace-dir if the last member of that class
    leaves the directory.

    There may be locking or refcounting fixes left, I stopped when it seemed
    to work with network and sound modules. :)

    From: Kay Sievers
    Signed-off-by: Greg Kroah-Hartman

    Kay Sievers
     

24 Feb, 2007

1 commit


17 Feb, 2007

1 commit


08 Feb, 2007

1 commit


14 Dec, 2006

1 commit


02 Dec, 2006

2 commits


19 Oct, 2006

1 commit


30 Sep, 2006

1 commit


26 Sep, 2006

5 commits


01 Jul, 2006

1 commit


22 Jun, 2006

5 commits


07 May, 2006

1 commit

  • Extend the support of attribute groups in class_device's to allow
    groups to be created as part of the registration process. This allows
    network device's to avoid race between registration and creating
    groups.

    Note that unlike attributes that are a property of the class object,
    the groups are a property of the class_device object. This is done
    because there are different types of network devices (wireless for
    example).

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Greg Kroah-Hartman
    Signed-off-by: David S. Miller

    Stephen Hemminger
     

15 Apr, 2006

1 commit


05 Jan, 2006

1 commit


31 Oct, 2005

1 commit

  • I recently picked up my older work to remove unnecessary #includes of
    sched.h, starting from a patch by Dave Jones to not include sched.h
    from module.h. This reduces the number of indirect includes of sched.h
    by ~300. Another ~400 pointless direct includes can be removed after
    this disentangling (patch to follow later).
    However, quite a few indirect includes need to be fixed up for this.

    In order to feed the patches through -mm with as little disturbance as
    possible, I've split out the fixes I accumulated up to now (complete for
    i386 and x86_64, more archs to follow later) and post them before the real
    patch. This way this large part of the patch is kept simple with only
    adding #includes, and all hunks are independent of each other. So if any
    hunk rejects or gets in the way of other patches, just drop it. My scripts
    will pick it up again in the next round.

    Signed-off-by: Tim Schmielau
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Tim Schmielau
     

29 Oct, 2005

4 commits

  • This patch allows struct class_device to be nested, so that another
    struct class_device can be the parent of a new one, instead of only
    having the struct class be the parent. This will allow us to
    (hopefully) fix up the input and video class subsystem mess.

    But please people, don't go crazy and start making huge trees of class
    devices, you should only need 2 levels deep to get everything to work
    (remember to use a class_interface to get notification of a new class
    device being added to the system.)

    Oh, this also allows us to have the possibility of potentially, someday,
    moving /sys/block into /sys/class. The main hindrance is that pesky
    /dev numberspace issue...

    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     
  • A "coldplug + udevstart" can be simple like this:
    for i in /sys/block/*/*/uevent; do echo 1 > $i; done
    for i in /sys/class/*/*/uevent; do echo 1 > $i; done
    for i in /sys/bus/*/devices/*/uevent; do echo 1 > $i; done

    Signed-off-by: Kay Sievers
    Signed-off-by: Greg Kroah-Hartman

    Kay Sievers
     
  • Driver core: pass interface to class intreface methods

    Pass interface as argument to add() and remove() class interface
    methods. This way a subsystem can implement generic add/remove
    handlers and then call interface-specific ones.

    Signed-off-by: Dmitry Torokhov
    Signed-off-by: Greg Kroah-Hartman

    Dmitry Torokhov
     
  • Move call to kobject_hotplug() above code that adds interfaces
    to a class device, otherwise children's hotplug events may reach
    userspace first.

    Signed-off-by: Dmitry Torokhov
    Signed-off-by: Greg Kroah-Hartman

    Dmitry Torokhov
     

22 Sep, 2005

1 commit

  • The class symlinks in sysfs don't properly handle changing device names.

    To demonstrate, rename your network device from eth0 to eth1. Your
    pci (or usb, or whatever) device will still have a 'net:eth0' link,
    except now it points to /sys/class/net/eth1.

    The attached patch makes sure the class symlink name changes when
    the class device name changes. It isn't 100% correct, it should be
    using sysfs_rename_link. Unfortunately, sysfs_rename_link doesn't exist.

    Signed-off-by: Bill Nottingham
    Signed-off-by: Greg Kroah-Hartman
    Signed-off-by: Linus Torvalds

    Bill Nottingham
     

13 Sep, 2005

1 commit