]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/linux/pci.h
rename DECLARE_PCI_DEVICE_TABLE to DEFINE_PCI_DEVICE_TABLE
[linux-2.6-omap-h63xx.git] / include / linux / pci.h
index 7215d3b1f4af05d8731e6dc4989763be0aea6eb0..38eff1947750aed9e4499e85d974b31c473f5b52 100644 (file)
@@ -301,14 +301,14 @@ struct pci_ops {
        int (*write)(struct pci_bus *bus, unsigned int devfn, int where, int size, u32 val);
 };
 
-struct pci_raw_ops {
-       int (*read)(unsigned int domain, unsigned int bus, unsigned int devfn,
-                   int reg, int len, u32 *val);
-       int (*write)(unsigned int domain, unsigned int bus, unsigned int devfn,
-                    int reg, int len, u32 val);
-};
-
-extern struct pci_raw_ops *raw_pci_ops;
+/*
+ * ACPI needs to be able to access PCI config space before we've done a
+ * PCI bus scan and created pci_bus structures.
+ */
+extern int raw_pci_read(unsigned int domain, unsigned int bus,
+                       unsigned int devfn, int reg, int len, u32 *val);
+extern int raw_pci_write(unsigned int domain, unsigned int bus,
+                       unsigned int devfn, int reg, int len, u32 val);
 
 struct pci_bus_region {
        resource_size_t start;
@@ -388,6 +388,16 @@ struct pci_driver {
 
 #define        to_pci_driver(drv) container_of(drv, struct pci_driver, driver)
 
+/**
+ * DEFINE_PCI_DEVICE_TABLE - macro used to describe a pci device table
+ * @_table: device table name
+ *
+ * This macro is used to create a struct pci_device_id array (a device table)
+ * in a generic manner.
+ */
+#define DEFINE_PCI_DEVICE_TABLE(_table) \
+       const struct pci_device_id _table[] __devinitconst
+
 /**
  * PCI_DEVICE - macro used to describe a specific pci device
  * @vend: the 16 bit PCI Vendor ID