diff options
| author | Greg Kroah-Hartman <greg@kroah.com> | 2003-02-07 12:01:18 +1100 |
|---|---|---|
| committer | Greg Kroah-Hartman <greg@kroah.com> | 2003-02-07 12:01:18 +1100 |
| commit | 19685246a2be2a4d6684c0231ec0b2aacf8d4c31 (patch) | |
| tree | 5c9b6a95ebbdc0a9fda0f5a317dd1d44abb86ba2 /include | |
| parent | 7d5bea384ce13d3f435ec587e5b96a5324b16fd3 (diff) | |
| parent | b8d261e0471deea68cec20d607f0fd42aa4bc91a (diff) | |
Merge kroah.com:/home/greg/linux/BK/bleed-2.5
into kroah.com:/home/greg/linux/BK/pci-hp-2.5
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/pci.h | 31 | ||||
| -rw-r--r-- | include/linux/sysfs.h | 3 |
2 files changed, 34 insertions, 0 deletions
diff --git a/include/linux/pci.h b/include/linux/pci.h index 7b693e39425f..7b42110379ac 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -671,6 +671,37 @@ void pci_pool_free (struct pci_pool *pool, void *vaddr, dma_addr_t addr); extern struct pci_dev *isa_bridge; #endif +/* Some worker functions that PCI Hotplug drivers find useful */ +struct pci_dev_wrapped { + struct pci_dev *dev; + void *data; +}; + +struct pci_bus_wrapped { + struct pci_bus *bus; + void *data; +}; + +struct pci_visit { + int (* pre_visit_pci_bus) (struct pci_bus_wrapped *, + struct pci_dev_wrapped *); + int (* post_visit_pci_bus) (struct pci_bus_wrapped *, + struct pci_dev_wrapped *); + + int (* pre_visit_pci_dev) (struct pci_dev_wrapped *, + struct pci_bus_wrapped *); + int (* visit_pci_dev) (struct pci_dev_wrapped *, + struct pci_bus_wrapped *); + int (* post_visit_pci_dev) (struct pci_dev_wrapped *, + struct pci_bus_wrapped *); +}; + +extern int pci_visit_dev(struct pci_visit *fn, + struct pci_dev_wrapped *wrapped_dev, + struct pci_bus_wrapped *wrapped_parent); +extern int pci_is_dev_in_use(struct pci_dev *dev); +extern int pci_remove_device_safe(struct pci_dev *dev); + #endif /* CONFIG_PCI */ /* Include architecture-dependent settings and functions */ diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h index 6a4cb2ffeaa9..9d0be48ba34c 100644 --- a/include/linux/sysfs.h +++ b/include/linux/sysfs.h @@ -30,6 +30,9 @@ sysfs_remove_dir(struct kobject *); extern int sysfs_create_file(struct kobject *, struct attribute *); +extern int +sysfs_update_file(struct kobject *, struct attribute *); + extern void sysfs_remove_file(struct kobject *, struct attribute *); |
