diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2008-03-26 21:44:58 -0400 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2008-03-26 15:33:40 -0400 |
commit | 27eedbf557f511efbe5651fa2fbfa0e4e8315ab7 (patch) | |
tree | f6052a79d7c8a5bb329685426148cab8641b6388 /arch | |
parent | c3a1c9c75b986e5a2c5d878ef0700a1ca6bb895a (diff) |
iop: when scanning PCI bus, translate the PCI addresses according to the outbound window settings
... otherwise we end up trying to access peripherals using wrong PCI
addresses.
Cc: Lennert Buytenhek <kernel@wantstofly.org>
Acked-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/plat-iop/pci.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/arch/arm/plat-iop/pci.c b/arch/arm/plat-iop/pci.c index 9e83066cc056..ee6deaabf9b5 100644 --- a/arch/arm/plat-iop/pci.c +++ b/arch/arm/plat-iop/pci.c | |||
@@ -209,8 +209,11 @@ int iop3xx_pci_setup(int nr, struct pci_sys_data *sys) | |||
209 | res[1].flags = IORESOURCE_MEM; | 209 | res[1].flags = IORESOURCE_MEM; |
210 | request_resource(&iomem_resource, &res[1]); | 210 | request_resource(&iomem_resource, &res[1]); |
211 | 211 | ||
212 | sys->mem_offset = IOP3XX_PCI_LOWER_MEM_PA - IOP3XX_PCI_LOWER_MEM_BA; | 212 | /* |
213 | sys->io_offset = IOP3XX_PCI_LOWER_IO_PA - IOP3XX_PCI_LOWER_IO_BA; | 213 | * Use whatever translation is already setup. |
214 | */ | ||
215 | sys->mem_offset = IOP3XX_PCI_LOWER_MEM_PA - *IOP3XX_OMWTVR0; | ||
216 | sys->io_offset = IOP3XX_PCI_LOWER_IO_PA - *IOP3XX_OIOWTVR; | ||
214 | 217 | ||
215 | sys->resource[0] = &res[0]; | 218 | sys->resource[0] = &res[0]; |
216 | sys->resource[1] = &res[1]; | 219 | sys->resource[1] = &res[1]; |