sh: pci: New-style controller registration.

This moves off of the board_pci_channels[] approach for bus registration
and over to a cleaner register_pci_controller(), all derived from the
MIPS code.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>
This commit is contained in:
Paul Mundt
2009-04-20 18:29:22 +09:00
parent 99f95f1178
commit e79066a659
3 changed files with 132 additions and 85 deletions

View File

@ -17,17 +17,22 @@
* external) PCI controllers.
*/
struct pci_channel {
int (*init)(struct pci_channel *chan);
struct pci_ops *pci_ops;
struct resource *io_resource;
struct resource *mem_resource;
int first_devfn;
int last_devfn;
int enabled;
unsigned long reg_base;
unsigned long io_base;
struct pci_channel *next;
unsigned long io_map_base;
int (*init)(struct pci_channel *chan);
struct pci_ops *pci_ops;
struct resource *io_resource;
struct resource *mem_resource;
int first_devfn;
int last_devfn;
int enabled;
unsigned long reg_base;
unsigned long io_base;
unsigned long io_map_base;
};
/*
@ -35,6 +40,8 @@ struct pci_channel {
*/
extern struct pci_channel board_pci_channels[];
extern void register_pci_controller(struct pci_channel *hose);
extern unsigned long PCIBIOS_MIN_IO, PCIBIOS_MIN_MEM;
struct pci_dev;