diff options
| author | <jgarzik@pretzel.yyz.us> | 2005-05-27 22:08:07 -0400 |
|---|---|---|
| committer | Jeff Garzik <jgarzik@pobox.com> | 2005-05-27 22:08:07 -0400 |
| commit | 51a730d758ae4052e10ca7e06336f10af598c4fc (patch) | |
| tree | b76a004c00cd7139659be515ee03398e47067290 /drivers/pci/pci-sysfs.c | |
| parent | 6cd15a9daf826115356f9403494c76e5aafa7793 (diff) | |
| parent | ff0e0ea2f5d36fa90fc2c57fd019102b0a0cfabf (diff) | |
Automatic merge of /spare/repo/netdev-2.6 branch we18-ieee80211
Diffstat (limited to 'drivers/pci/pci-sysfs.c')
| -rw-r--r-- | drivers/pci/pci-sysfs.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c index 8568b207f189..6ca0061137a6 100644 --- a/drivers/pci/pci-sysfs.c +++ b/drivers/pci/pci-sysfs.c | |||
| @@ -73,6 +73,17 @@ resource_show(struct device * dev, char * buf) | |||
| 73 | return (str - buf); | 73 | return (str - buf); |
| 74 | } | 74 | } |
| 75 | 75 | ||
| 76 | static ssize_t modalias_show(struct device *dev, char *buf) | ||
| 77 | { | ||
| 78 | struct pci_dev *pci_dev = to_pci_dev(dev); | ||
| 79 | |||
| 80 | return sprintf(buf, "pci:v%08Xd%08Xsv%08Xsd%08Xbc%02Xsc%02Xi%02x\n", | ||
| 81 | pci_dev->vendor, pci_dev->device, | ||
| 82 | pci_dev->subsystem_vendor, pci_dev->subsystem_device, | ||
| 83 | (u8)(pci_dev->class >> 16), (u8)(pci_dev->class >> 8), | ||
| 84 | (u8)(pci_dev->class)); | ||
| 85 | } | ||
| 86 | |||
| 76 | struct device_attribute pci_dev_attrs[] = { | 87 | struct device_attribute pci_dev_attrs[] = { |
| 77 | __ATTR_RO(resource), | 88 | __ATTR_RO(resource), |
| 78 | __ATTR_RO(vendor), | 89 | __ATTR_RO(vendor), |
| @@ -82,6 +93,7 @@ struct device_attribute pci_dev_attrs[] = { | |||
| 82 | __ATTR_RO(class), | 93 | __ATTR_RO(class), |
| 83 | __ATTR_RO(irq), | 94 | __ATTR_RO(irq), |
| 84 | __ATTR_RO(local_cpus), | 95 | __ATTR_RO(local_cpus), |
| 96 | __ATTR_RO(modalias), | ||
| 85 | __ATTR_NULL, | 97 | __ATTR_NULL, |
| 86 | }; | 98 | }; |
| 87 | 99 | ||
