diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-19 12:59:55 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-19 12:59:55 -0800 |
commit | 733abe4fff3afa13e301bc8bc5bee9aac4b59fdc (patch) | |
tree | c11f08a401783848deb7f41f65e990333971ba66 /drivers/pci/pci-sysfs.c | |
parent | 5fe8252fc3a21666cf19053fbd7ec7bd9664f5d9 (diff) | |
parent | 81bb0e198b4638ac65233b316f4588639dfe1fcd (diff) | |
download | talos-obmc-linux-733abe4fff3afa13e301bc8bc5bee9aac4b59fdc.tar.gz talos-obmc-linux-733abe4fff3afa13e301bc8bc5bee9aac4b59fdc.zip |
Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/pci-2.6:
PCI: Make PCI device numa-node attribute visible in sysfs
PCI: add systems for automatic breadth-first device sorting
PCI: PCI devices get assigned redundant IRQs
PCI: Make CARDBUS_MEM_SIZE and CARDBUS_IO_SIZE boot options
PCI: pci.txt fix __devexit() usage
PCI/sysfs/kobject kernel-doc fixes
Diffstat (limited to 'drivers/pci/pci-sysfs.c')
-rw-r--r-- | drivers/pci/pci-sysfs.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c index 7a94076752d0..cd913a2a416f 100644 --- a/drivers/pci/pci-sysfs.c +++ b/drivers/pci/pci-sysfs.c @@ -143,6 +143,14 @@ static ssize_t is_enabled_show(struct device *dev, return sprintf (buf, "%u\n", atomic_read(&pdev->enable_cnt)); } +#ifdef CONFIG_NUMA +static ssize_t +numa_node_show(struct device *dev, struct device_attribute *attr, char *buf) +{ + return sprintf (buf, "%d\n", dev->numa_node); +} +#endif + static ssize_t msi_bus_show(struct device *dev, struct device_attribute *attr, char *buf) { @@ -194,6 +202,9 @@ struct device_attribute pci_dev_attrs[] = { __ATTR_RO(irq), __ATTR_RO(local_cpus), __ATTR_RO(modalias), +#ifdef CONFIG_NUMA + __ATTR_RO(numa_node), +#endif __ATTR(enable, 0600, is_enabled_show, is_enabled_store), __ATTR(broken_parity_status,(S_IRUGO|S_IWUSR), broken_parity_status_show,broken_parity_status_store), |