2 * arch/arm/include/asm/mach/pci.h
4 * Copyright (C) 2000 Russell King
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
11 #ifndef __ASM_MACH_PCI_H
12 #define __ASM_MACH_PCI_H
20 #ifdef CONFIG_PCI_DOMAINS
25 int (*setup)(int nr, struct pci_sys_data *);
26 struct pci_bus *(*scan)(int nr, struct pci_sys_data *);
27 void (*preinit)(void);
28 void (*postinit)(void);
29 u8 (*swizzle)(struct pci_dev *dev, u8 *pin);
30 int (*map_irq)(const struct pci_dev *dev, u8 slot, u8 pin);
34 * Per-controller structure
37 #ifdef CONFIG_PCI_DOMAINS
40 struct list_head node;
41 int busnr; /* primary bus number */
42 u64 mem_offset; /* bus->cpu memory mapping offset */
43 unsigned long io_offset; /* bus->cpu IO mapping offset */
44 struct pci_bus *bus; /* PCI bus */
45 struct list_head resources; /* root bus resources (apertures) */
46 /* Bridge swizzling */
47 u8 (*swizzle)(struct pci_dev *, u8 *);
49 int (*map_irq)(const struct pci_dev *, u8, u8);
50 void *private_data; /* platform controller private data */
54 * Call this with your hw_pci struct to initialise the PCI system.
56 void pci_common_init(struct hw_pci *);
59 * Setup early fixed I/O mapping.
61 #if defined(CONFIG_PCI)
62 extern void pci_map_io_early(unsigned long pfn);
64 static inline void pci_map_io_early(unsigned long pfn) {}
70 extern struct pci_ops iop3xx_ops;
71 extern int iop3xx_pci_setup(int nr, struct pci_sys_data *);
72 extern void iop3xx_pci_preinit(void);
73 extern void iop3xx_pci_preinit_cond(void);
75 extern struct pci_ops dc21285_ops;
76 extern int dc21285_setup(int nr, struct pci_sys_data *);
77 extern void dc21285_preinit(void);
78 extern void dc21285_postinit(void);
80 extern struct pci_ops via82c505_ops;
81 extern int via82c505_setup(int nr, struct pci_sys_data *);
82 extern void via82c505_init(void *sysdata);
84 extern struct pci_ops pci_v3_ops;
85 extern int pci_v3_setup(int nr, struct pci_sys_data *);
86 extern void pci_v3_preinit(void);
87 extern void pci_v3_postinit(void);
89 #endif /* __ASM_MACH_PCI_H */