summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/asm-alpha/pci.h5
-rw-r--r--include/asm-arm/pci.h4
-rw-r--r--include/asm-generic/pci.h25
-rw-r--r--include/asm-i386/pci.h3
-rw-r--r--include/asm-ia64/pci.h3
-rw-r--r--include/asm-mips/pci.h3
-rw-r--r--include/asm-mips64/pci.h4
-rw-r--r--include/asm-parisc/pci.h4
-rw-r--r--include/asm-ppc/pci.h3
-rw-r--r--include/asm-ppc64/pci.h3
-rw-r--r--include/asm-sh/pci.h2
-rw-r--r--include/asm-sparc64/pci.h3
-rw-r--r--include/asm-x86_64/pci.h3
-rw-r--r--include/linux/pci.h9
14 files changed, 68 insertions, 6 deletions
diff --git a/include/asm-alpha/pci.h b/include/asm-alpha/pci.h
index 3f88b46f8dfe..1e82bf33cb84 100644
--- a/include/asm-alpha/pci.h
+++ b/include/asm-alpha/pci.h
@@ -190,6 +190,11 @@ pci_dac_dma_sync_single(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len,
/* Return the index of the PCI controller for device PDEV. */
extern int pci_controller_num(struct pci_dev *pdev);
+
+extern void
+pcibios_resource_to_bus(struct pci_dev *dev, struct pci_bus_region *region,
+ struct resource *res);
+
#endif /* __KERNEL__ */
/* Values for the `which' argument to sys_pciconfig_iobase. */
diff --git a/include/asm-arm/pci.h b/include/asm-arm/pci.h
index 193c96e1609f..72843a2888b5 100644
--- a/include/asm-arm/pci.h
+++ b/include/asm-arm/pci.h
@@ -175,6 +175,10 @@ void pci_pool_free (struct pci_pool *pool, void *vaddr, dma_addr_t addr);
extern int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma,
enum pci_mmap_state mmap_state, int write_combine);
+extern void
+pcibios_resource_to_bus(struct pci_dev *dev, struct pci_bus_region *region,
+ struct resource *res);
+
#endif /* __KERNEL__ */
#endif
diff --git a/include/asm-generic/pci.h b/include/asm-generic/pci.h
new file mode 100644
index 000000000000..df757d240e9a
--- /dev/null
+++ b/include/asm-generic/pci.h
@@ -0,0 +1,25 @@
+/*
+ * linux/include/asm-generic/pci.h
+ *
+ * Copyright (C) 2003 Russell King
+ */
+#ifndef _ASM_GENERIC_PCI_H
+#define _ASM_GENERIC_PCI_H
+
+/**
+ * pcibios_resource_to_bus - convert resource to PCI bus address
+ * @dev: device which owns this resource
+ * @region: converted bus-centric region (start,end)
+ * @res: resource to convert
+ *
+ * Convert a resource to a PCI device bus address or bus window.
+ */
+static inline void
+pcibios_resource_to_bus(struct pci_dev *dev, struct pci_bus_region *region,
+ struct resource *res)
+{
+ region->start = res->start;
+ region->end = res->end;
+}
+
+#endif
diff --git a/include/asm-i386/pci.h b/include/asm-i386/pci.h
index d41feaba85ef..e0e0442260df 100644
--- a/include/asm-i386/pci.h
+++ b/include/asm-i386/pci.h
@@ -105,4 +105,7 @@ extern int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma,
/* implement the pci_ DMA API in terms of the generic device dma_ one */
#include <asm-generic/pci-dma-compat.h>
+/* generic pci stuff */
+#include <asm-generic/pci.h>
+
#endif /* __i386_PCI_H */
diff --git a/include/asm-ia64/pci.h b/include/asm-ia64/pci.h
index 62a7d5a544d5..69a58612d87b 100644
--- a/include/asm-ia64/pci.h
+++ b/include/asm-ia64/pci.h
@@ -97,4 +97,7 @@ extern int pcibios_prep_mwi (struct pci_dev *);
extern int pci_mmap_page_range (struct pci_dev *dev, struct vm_area_struct *vma,
enum pci_mmap_state mmap_state, int write_combine);
+/* generic pci stuff */
+#include <asm-generic/pci.h>
+
#endif /* _ASM_IA64_PCI_H */
diff --git a/include/asm-mips/pci.h b/include/asm-mips/pci.h
index 84c9bd2b9bfb..98b248e8cd29 100644
--- a/include/asm-mips/pci.h
+++ b/include/asm-mips/pci.h
@@ -252,4 +252,7 @@ extern inline int pci_dma_supported(struct pci_dev *hwdev, u64 mask)
#endif /* __KERNEL__ */
+/* generic pci stuff */
+#include <asm-generic/pci.h>
+
#endif /* _ASM_PCI_H */
diff --git a/include/asm-mips64/pci.h b/include/asm-mips64/pci.h
index a7cc388c5824..730e04075480 100644
--- a/include/asm-mips64/pci.h
+++ b/include/asm-mips64/pci.h
@@ -272,4 +272,8 @@ static inline int pci_dma_supported(struct pci_dev *hwdev, u64 mask)
#endif /* __KERNEL__ */
+/* generic pci stuff */
+#include <asm-generic/pci.h>
+
#endif /* _ASM_PCI_H */
+
diff --git a/include/asm-parisc/pci.h b/include/asm-parisc/pci.h
index 2dbd703983e7..d44ad70d0e35 100644
--- a/include/asm-parisc/pci.h
+++ b/include/asm-parisc/pci.h
@@ -186,4 +186,8 @@ extern inline void pcibios_register_hba(struct pci_hba_data *x)
/* export the pci_ DMA API in terms of the dma_ one */
#include <asm-generic/pci-dma-compat.h>
+extern void
+pcibios_resource_to_bus(struct pci_dev *dev, struct pci_bus_region *region,
+ struct resource *res);
+
#endif /* __ASM_PARISC_PCI_H */
diff --git a/include/asm-ppc/pci.h b/include/asm-ppc/pci.h
index 92118321f0a5..c178b8e5d4b3 100644
--- a/include/asm-ppc/pci.h
+++ b/include/asm-ppc/pci.h
@@ -273,4 +273,7 @@ int pci_mmap_page_range(struct pci_dev *pdev, struct vm_area_struct *vma,
#endif /* __KERNEL__ */
+/* generic pci stuff */
+#include <asm-generic/pci.h>
+
#endif /* __PPC_PCI_H */
diff --git a/include/asm-ppc64/pci.h b/include/asm-ppc64/pci.h
index 0b715895f043..2cab41c41cca 100644
--- a/include/asm-ppc64/pci.h
+++ b/include/asm-ppc64/pci.h
@@ -124,4 +124,7 @@ int pci_mmap_page_range(struct pci_dev *pdev, struct vm_area_struct *vma,
#endif /* __KERNEL__ */
+/* generic pci stuff */
+#include <asm-generic/pci.h>
+
#endif /* __PPC64_PCI_H */
diff --git a/include/asm-sh/pci.h b/include/asm-sh/pci.h
index f9690c521d19..60fffd091ad6 100644
--- a/include/asm-sh/pci.h
+++ b/include/asm-sh/pci.h
@@ -240,6 +240,8 @@ static inline int pci_dma_supported(struct pci_dev *hwdev, u64 mask)
#endif /* __KERNEL__ */
+/* generic pci stuff */
+#include <asm-generic/pci.h>
#endif /* __ASM_SH_PCI_H */
diff --git a/include/asm-sparc64/pci.h b/include/asm-sparc64/pci.h
index 53a010006c41..6b97445a221a 100644
--- a/include/asm-sparc64/pci.h
+++ b/include/asm-sparc64/pci.h
@@ -207,4 +207,7 @@ extern int pcibios_prep_mwi(struct pci_dev *dev);
#endif /* __KERNEL__ */
+/* generic pci stuff */
+#include <asm-generic/pci.h>
+
#endif /* __SPARC64_PCI_H */
diff --git a/include/asm-x86_64/pci.h b/include/asm-x86_64/pci.h
index 024a9c045681..74594c63e38c 100644
--- a/include/asm-x86_64/pci.h
+++ b/include/asm-x86_64/pci.h
@@ -279,4 +279,7 @@ extern int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma,
#endif /* __KERNEL__ */
+/* generic pci stuff */
+#include <asm-generic/pci.h>
+
#endif /* __x8664_PCI_H */
diff --git a/include/linux/pci.h b/include/linux/pci.h
index 0bc50220c102..b01ae2e4df9c 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -485,11 +485,9 @@ struct pci_ops {
int (*write)(struct pci_bus *bus, unsigned int devfn, int where, int size, u32 val);
};
-struct pbus_set_ranges_data
-{
- unsigned long io_start, io_end;
- unsigned long mem_start, mem_end;
- unsigned long prefetch_start, prefetch_end;
+struct pci_bus_region {
+ unsigned long start;
+ unsigned long end;
};
struct pci_driver {
@@ -533,7 +531,6 @@ void pcibios_align_resource(void *, struct resource *,
unsigned long, unsigned long);
void pcibios_update_resource(struct pci_dev *, struct resource *, int);
void pcibios_update_irq(struct pci_dev *, int irq);
-void pcibios_fixup_pbus_ranges(struct pci_bus *, struct pbus_set_ranges_data *);
/* Generic PCI functions used internally */