X-Git-Url: http://git.ozo.com/?p=openwrt-10.03%2F.git;a=blobdiff_plain;f=target%2Flinux%2Fbrcm63xx-2.6%2Ffiles%2Farch%2Fmips%2Fpci%2Fpci-bcm96348.c;h=b477e827bda3a09e284dcca99f4c2c042eab9c8d;hp=31e9d161abf4fb4f17c967ac856bfea93e0d5b12;hb=b774eb69b924f3a1c55dd36bc8c4fe6ba0ab5abc;hpb=147d8ef4ccbc77883aaa772471e6cd9e879bbafe diff --git a/target/linux/brcm63xx-2.6/files/arch/mips/pci/pci-bcm96348.c b/target/linux/brcm63xx-2.6/files/arch/mips/pci/pci-bcm96348.c index 31e9d161a..b477e827b 100644 --- a/target/linux/brcm63xx-2.6/files/arch/mips/pci/pci-bcm96348.c +++ b/target/linux/brcm63xx-2.6/files/arch/mips/pci/pci-bcm96348.c @@ -21,34 +21,42 @@ #include #include -//#include #include static struct resource bcm_pci_io_resource = { - .name = "bcm96348 pci IO space", - .start = BCM_PCI_IO_BASE, - .end = BCM_PCI_IO_BASE + BCM_PCI_IO_SIZE_64KB - 1, - .flags = IORESOURCE_IO + .name = "bcm96348 pci IO space", + .start = BCM_PCI_IO_BASE, + .end = BCM_PCI_IO_BASE + BCM_PCI_IO_SIZE_64KB - 1, + .flags = IORESOURCE_IO }; static struct resource bcm_pci_mem_resource = { - .name = "bcm96348 pci memory space", - .start = BCM_PCI_MEM_BASE, - .end = BCM_PCI_MEM_BASE + BCM_PCI_MEM_SIZE_16MB - 1, - .flags = IORESOURCE_MEM + .name = "bcm96348 pci memory space", + .start = BCM_PCI_MEM_BASE, + .end = BCM_PCI_MEM_BASE + BCM_PCI_MEM_SIZE_16MB - 1, + .flags = IORESOURCE_MEM }; extern struct pci_ops bcm96348_pci_ops; struct pci_controller bcm96348_controller = { - .pci_ops = &bcm96348_pci_ops, - .io_resource = &bcm_pci_io_resource, - .mem_resource = &bcm_pci_mem_resource, + .pci_ops = &bcm96348_pci_ops, + .io_resource = &bcm_pci_io_resource, + .mem_resource = &bcm_pci_mem_resource, }; -static void bcm96348_pci_init(void) +static __init int bcm96348_pci_init(void) { - register_pci_controller(&bcm96348_controller); + /* Avoid ISA compat ranges. */ + PCIBIOS_MIN_IO = 0x00000000; + PCIBIOS_MIN_MEM = 0x00000000; + + /* Set I/O resource limits. */ + ioport_resource.end = 0x1fffffff; + iomem_resource.end = 0xffffffff; + + register_pci_controller(&bcm96348_controller); + return 0; } -arch_initcall(bcm96348_pci_init); +subsys_initcall(bcm96348_pci_init);