summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* class: fix docbook comments for class_private structureGreg Kroah-Hartman2008-07-211-2/+1
| | | | | | | | Removes a field that has been deleted, and adds a description fo the class_dirs field which was previously undocumented. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* class: rename "sem" to "class_sem" in internal class structureGreg Kroah-Hartman2008-07-213-17/+17
| | | | | | | | | | | This renames the struct class "sem" field to be "class_sem" to make things easier when struct bus_type and struct class merge in the future. It also makes grepping for fields easier as well. Based on an idea from Kay. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* class: rename "subsys" to "class_subsys" in internal class structureGreg Kroah-Hartman2008-07-213-28/+33
| | | | | | | | | | | This renames the struct class "subsys" field to be "class_subsys" to make things easier when struct bus_type and struct class merge in the future. It also makes grepping for fields easier as well. Based on an idea from Kay. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* class: rename "interfaces" to "class_interfaces" in internal class structureGreg Kroah-Hartman2008-07-213-8/+8
| | | | | | | | | | | | This renames the struct class "interfaces" field to be "class_interfaces" to make things easier when struct bus_type and struct class merge in the future. It also makes grepping for fields easier as well. Based on an idea from Kay. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* class: rename "devices" to "class_devices" in internal class structureGreg Kroah-Hartman2008-07-213-8/+8
| | | | | | | | | | | This renames the struct class "devices" field to be "class_devices" to make things easier when struct bus_type and struct class merge in the future. It also makes grepping for fields easier as well. Based on an idea from Kay. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* class: move driver core specific parts to a private structureGreg Kroah-Hartman2008-07-214-71/+107
| | | | | | | | | | | This moves the portions of struct class that are dynamic (kobject and lock and lists) out of the main structure and into a dynamic, private, structure. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* bluetooth: remove improper bluetooth class symlinks.Greg Kroah-Hartman2008-07-211-7/+0
| | | | | | | | | | | | Don't create symlinks in a class to a device that is not owned by the class. If the bluetooth subsystem really wants to point to all of the devices it controls, it needs to create real devices, not fake symlinks. Cc: Maxim Krasnyansky <maxk@qualcomm.com> Cc: Kay Sievers <kay.sievers@vrfy.org> Acked-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* infiniband: make cm_device use a struct device and not a kobject.Greg Kroah-Hartman2008-07-211-20/+9
| | | | | | | | | | | | | | | | This object really should be a struct device, or at least contain a pointer to a struct device, as it is trying to create a separate device tree outside of the main device tree. This patch fixes this problem. It is needed for the class core rework that is being done in the driver core. Cc: Kay Sievers <kay.sievers@vrfy.org> Cc: Roland Dreier <rolandd@cisco.com> Cc: Sean Hefty <sean.hefty@intel.com> Cc: Hal Rosenstock <hal.rosenstock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* infiniband: rename "device" to "ib_device" in cm_deviceGreg Kroah-Hartman2008-07-211-23/+24
| | | | | | | | | | | | | | This pointer really is a struct ib_device, not a struct device, so name it properly to help prevent confusion. This makes the followon patch in this series much smaller and easier to understand as well. Cc: Kay Sievers <kay.sievers@vrfy.org> Cc: Roland Dreier <rolandd@cisco.com> Cc: Hal Rosenstock <hal.rosenstock@gmail.com> Acked-by: Sean Hefty <sean.hefty@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* block: make /proc/partitions and /proc/diskstats use class_find_device()Greg Kroah-Hartman2008-07-211-12/+13
| | | | | | | | Use the proper class iterator function instead of mucking around in the internals of the class structures. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* block: move header for /proc/partitions to seq_startGreg Kroah-Hartman2008-07-211-3/+4
| | | | | | | | | The seq_start call is the better place for the header for the file, that way we don't have to be mucking in the class structure to try to figure out if this is the first partition or not. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* block: make proc files seq_start use the class_find_device()Greg Kroah-Hartman2008-07-211-14/+17
| | | | | | | | Use the proper class iterator function instead of mucking around in the internals of the class structures. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* block: make /proc/diskstats only build if CONFIG_PROC_FS is enabledRandy Dunlap2008-07-211-0/+2
| | | | | | | | | | | These functions are only needed if CONFIG_PROC_FS is enabled, so save the space when it is not. This also makes it easier for a patch later in this series to work properly if CONFIG_PROC_FS is not enabled. Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* block: make blk_lookup_devt use the class iterator functionGreg Kroah-Hartman2008-07-211-12/+26
| | | | | | | | Use the proper class iterator function instead of mucking around in the internals of the class structures. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* block: make printk_partition use the class iterator functionGreg Kroah-Hartman2008-07-211-43/+50
| | | | | | | | Use the proper class iterator function instead of mucking around in the internals of the class structures. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* block: fix compiler warning in genhd.cGreg Kroah-Hartman2008-07-211-1/+3
| | | | | | | Warn if something really bad happens if we can't create this link. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Driver Core: add ability for class_find_device to start in middle of listGreg Kroah-Hartman2008-07-218-19/+28
| | | | | | | | | | | | | | | This mirrors the functionality that driver_find_device has as well. We add a start variable, and all callers of the function are fixed up at the same time. The block layer will be using this new functionality in a follow-on patch. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Driver Core: add ability for class_for_each_device to start in middle of listGreg Kroah-Hartman2008-07-216-19/+31
| | | | | | | | | | | | | | | This mirrors the functionality that driver_for_each_device has as well. We add a start variable, and all callers of the function are fixed up at the same time. The block layer will be using this new functionality in a follow-on patch. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: convert device_create_drvdata to device_createGreg Kroah-Hartman2008-07-212-12/+8
| | | | | | | | | | Now that device_create() has been audited, rename things back to the original call to be sane. Keep the device_create_drvdata macro around to make merges easier. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* driver core: remove device_create()Greg Kroah-Hartman2008-07-212-37/+0
| | | | | | | | There are no more users of this, and it is racy. Use device_create_drvdata() or device_create_vargs() instead. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: x86: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-212-4/+4
| | | | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: usb: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-214-9/+11
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: spi: convert device_create to device_create_drvdataDavid Brownell2008-07-211-2/+2
| | | | | | | | | | | | | Switch over to use the shiny new device_create_drvdata() call instead of the original device_create() calls, so this continues to work after device_create() is removed. Note that this driver never had the race which motivated removing the original call; it locked correctly. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: sound: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-213-10/+14
| | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Jaroslav Kysela <perex@perex.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: scsi: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-2/+2
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: James E.J. Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: s390: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-213-12/+14
| | | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: net: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-212-4/+5
| | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: mtd: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-3/+6
| | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: misc: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-2/+3
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: mips: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-212-3/+4
| | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: macintosh: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-1/+2
| | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: isdn: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-1/+2
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: infiniband: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-1/+1
| | | | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Roland Dreier <rolandd@cisco.com> Cc: Sean Hefty <sean.hefty@intel.com> Cc: Hal Rosenstock <hal.rosenstock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: ieee1394: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-213-8/+9
| | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Ben Collins <ben.collins@ubuntu.com> Acked-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: ide: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-4/+6
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: i2c: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-3/+3
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Jean Delvare <khali@linux-fr.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: hwmon: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-1/+2
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Mark M. Hoffman <mhoffman@lightlink.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: hid: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-2/+3
| | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: framebuffer: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-212-3/+5
| | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Antonino Daplas <adaplas@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: dvb: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-2/+2
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: dca: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-3/+5
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: coda: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-211-2/+3
| | | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Jan Harkes <jaharkes@cs.cmu.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: char: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-2118-49/+61
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* device create: block: convert device_create to device_create_drvdataGreg Kroah-Hartman2008-07-215-10/+17
| | | | | | | | device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Firmware: fix typo in example codeGreg Kroah-Hartman2008-07-211-1/+1
| | | | | | | | | It's not like this stuff even builds right now, but this will make Randy's scripts happy :) Cc: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* debugfs: Add a reference to the debugfs API documentation.Robert P. J. Day2008-07-211-0/+3
| | | | | | | Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Cc: Jesper Juhl <jesper.juhl@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* kobject: replace '/' with '!' in nameKay Sievers2008-07-211-2/+8
| | | | | | | | | | Some (block) devices have a '/' in the name, and need special handling. Let's have that rule to the core, so we can remove it from the block class. Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* sysfs: add /sys/dev/{char,block} to lookup sysfs path by major:minorDan Williams2008-07-217-2/+124
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Why?: There are occasions where userspace would like to access sysfs attributes for a device but it may not know how sysfs has named the device or the path. For example what is the sysfs path for /dev/disk/by-id/ata-ST3160827AS_5MT004CK? With this change a call to stat(2) returns the major:minor then userspace can see that /sys/dev/block/8:32 links to /sys/block/sdc. What are the alternatives?: 1/ Add an ioctl to return the path: Doable, but sysfs is meant to reduce the need to proliferate ioctl interfaces into the kernel, so this seems counter productive. 2/ Use udev to create these symlinks: Also doable, but it adds a udev dependency to utilities that might be running in a limited environment like an initramfs. 3/ Do a full-tree search of sysfs. [kay.sievers@vrfy.org: fix duplicate registrations] [kay.sievers@vrfy.org: cleanup suggestions] Cc: Neil Brown <neilb@suse.de> Cc: Tejun Heo <htejun@gmail.com> Acked-by: Kay Sievers <kay.sievers@vrfy.org> Reviewed-by: SL Baur <steve@xemacs.org> Acked-by: Kay Sievers <kay.sievers@vrfy.org> Acked-by: Mark Lord <lkml@rtr.ca> Acked-by: H. Peter Anvin <hpa@zytor.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6Linus Torvalds2008-07-21142-8951/+11623
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (100 commits) usb-storage: revert DMA-alignment change for Wireless USB USB: use reset_resume when normal resume fails usb_gadget: composite cdc gadget fault handling usb gadget: minor USBCV fix for composite framework USB: Fix bug with byte order in isp116x-hcd.c fio write/read USB: fix double kfree in ipaq in error case USB: fix build error in cdc-acm for CONFIG_PM=n USB: remove board-specific UP2OCR configuration from pxa27x-udc USB: EHCI: Reconciling USB register differences on MPC85xx vs MPC83xx USB: Fix pointer/int cast in USB devio code usb gadget: g_cdc dependso on NET USB: Au1xxx-usb: suspend/resume support. USB: Au1xxx-usb: clean up ohci/ehci bus glue sources. usbfs: don't store bad pointers in registration usbfs: fix race between open and unregister usbfs: simplify the lookup-by-minor routines usbfs: send disconnect signals when device is unregistered USB: Force unbinding of drivers lacking reset_resume or other methods USB: ohci-pnx4008: I2C cleanups and fixes USB: debug port converter does not accept more than 8 byte packets ...
| * usb-storage: revert DMA-alignment change for Wireless USBAlan Stern2008-07-211-10/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch (as1110) reverts an earlier patch meant to help with Wireless USB host controllers. These controllers can have bulk maxpacket values larger than 512, which puts unusual constraints on the sizes of scatter-gather list elements. However it turns out that the block layer does not provide the support we need to enforce these constraints; merely changing the DMA alignment mask doesn't help. Hence there's no reason to keep the original patch. The Wireless USB problem will have to be solved a different way. In addition, there is a reason to get rid of the earlier patch. By dereferencing a pointer stored in the ep_in array of struct usb_device, the current code risks an invalid memory access when it runs concurrently with device removal. The members of that array are cleared before the driver's disconnect method is called, so it should not try to use them. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
OpenPOWER on IntegriCloud