PCI: Introduce /sys/bus/pci/devices/.../remove
authorAlex Chiang <achiang@hp.com>
Fri, 20 Mar 2009 20:56:36 +0000 (14:56 -0600)
committerJesse Barnes <jbarnes@virtuousgeek.org>
Fri, 20 Mar 2009 21:58:48 +0000 (14:58 -0700)
commit77c27c7b49d69d45ccb94e481653f024f1ac6650
tree8f2e7a6f3971e3630ad1d219bee1c673597158fe
parent705b1aaa823e800490f157cd9366ad8cff385f5f
PCI: Introduce /sys/bus/pci/devices/.../remove

This patch adds an attribute named "remove" to a PCI device's sysfs
directory.  Writing a non-zero value to this attribute will remove the PCI
device and any children of it.

Trent Piepho wrote the original implementation and documentation.

Thanks to Vegard Nossum for testing under kmemcheck and finding locking
issues with the sysfs interface.

Cc: Trent Piepho <xyzzy@speakeasy.org>
Tested-by: Vegard Nossum <vegard.nossum@gmail.com>
Signed-off-by: Alex Chiang <achiang@hp.com>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Documentation/ABI/testing/sysfs-bus-pci
Documentation/filesystems/sysfs-pci.txt
drivers/pci/pci-sysfs.c