1
0
mirror of https://git.openwrt.org/openwrt/openwrt.git synced 2024-10-19 14:08:17 +02:00

cns3xxx: fix PCIe->PCI bridge access (fixes #18422)

Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 43414
This commit is contained in:
Felix Fietkau 2014-11-27 20:54:18 +00:00
parent ceccdc4a31
commit f473f95196

@ -0,0 +1,11 @@
--- a/arch/arm/mach-cns3xxx/pcie.c
+++ b/arch/arm/mach-cns3xxx/pcie.c
@@ -93,6 +93,8 @@ static void __iomem *cns3xxx_pci_cfg_bas
base = (void __iomem *)cnspci->cfg_bases[type].virtual;
offset = (devfn << 12) | (where & 0xffc);
+ if (busno > 1)
+ offset += busno << 20;
return base + offset;
}