[U-Boot] [PATCH 2/8] boston: Disable PCI bridge memory space alignment

Paul Burton paul.burton at mips.com
Tue Nov 21 20:33:41 UTC 2017


On the MIPS Boston development board we have an Intel EG20T Platform
Controller Hub connected to a Xilinx AXI to PCIe root port which is only
assigned a 1MB memory region. The Intel EG20T contains a bridge device
beneath which all of its peripheral devices can be found, and that
bridge device contains a ROM. If we align to 1MB when we encounter each
bridge device we therefore do something like this:

  - Start with bus_lower at 0x16000000.

  - Find the Xilinx root bridge, which has no visible BARs so we do very
    little to it.

  - Probe the bus beneath the Xilinx bridge device, aligning bus_lower
    to a 1MB boundary first. That leaves it still at 0x16000000.

  - Find the EG20T bridge device, which we find has a 64KiB ROM. We
    assign it the address range 0x16000000-0x1600ffff which leaves
    bus_lower at 0x16010000.

  - Probe the bus beneath the EG20T bridge device, aligning bus_lower to
    a 1MB boundary first. This leaves bus_lower at 0x16100000, which is
    the end of the available memory space.

  - Find the various peripheral devices the EG20T contains, but fail to
    assign any memory space to them since bus_lower is at the end of the
    memory space available to the PCI bus.

Fix this by disabling that 1MB alignment, which allows all of the EG20T
peripheral devices to be assigned memory space within the 1MB region
available.

Signed-off-by: Paul Burton <paul.burton at imgtec.com>
Cc: Daniel Schwierzeck <daniel.schwierzeck at gmail.com>
Cc: Simon Glass <sjg at chromium.org>
Cc: u-boot at lists.denx.de
Signed-off-by: Paul Burton <paul.burton at mips.com>
---

 configs/boston32r2_defconfig   | 1 +
 configs/boston32r2el_defconfig | 1 +
 configs/boston64r2_defconfig   | 1 +
 configs/boston64r2el_defconfig | 1 +
 4 files changed, 4 insertions(+)

diff --git a/configs/boston32r2_defconfig b/configs/boston32r2_defconfig
index b8c87caaf8..1d21f1643c 100644
--- a/configs/boston32r2_defconfig
+++ b/configs/boston32r2_defconfig
@@ -35,6 +35,7 @@ CONFIG_DM_ETH=y
 CONFIG_PCH_GBE=y
 CONFIG_PCI=y
 CONFIG_DM_PCI=y
+CONFIG_DM_PCI_BRIDGE_MEM_ALIGN=0x0
 CONFIG_PCI_XILINX=y
 CONFIG_SYS_NS16550=y
 CONFIG_LZ4=y
diff --git a/configs/boston32r2el_defconfig b/configs/boston32r2el_defconfig
index 5cc43880a3..d26adc68f2 100644
--- a/configs/boston32r2el_defconfig
+++ b/configs/boston32r2el_defconfig
@@ -36,6 +36,7 @@ CONFIG_DM_ETH=y
 CONFIG_PCH_GBE=y
 CONFIG_PCI=y
 CONFIG_DM_PCI=y
+CONFIG_DM_PCI_BRIDGE_MEM_ALIGN=0x0
 CONFIG_PCI_XILINX=y
 CONFIG_SYS_NS16550=y
 CONFIG_LZ4=y
diff --git a/configs/boston64r2_defconfig b/configs/boston64r2_defconfig
index c30e0b0903..1491575af5 100644
--- a/configs/boston64r2_defconfig
+++ b/configs/boston64r2_defconfig
@@ -36,6 +36,7 @@ CONFIG_DM_ETH=y
 CONFIG_PCH_GBE=y
 CONFIG_PCI=y
 CONFIG_DM_PCI=y
+CONFIG_DM_PCI_BRIDGE_MEM_ALIGN=0x0
 CONFIG_PCI_XILINX=y
 CONFIG_SYS_NS16550=y
 CONFIG_LZ4=y
diff --git a/configs/boston64r2el_defconfig b/configs/boston64r2el_defconfig
index b9506ccb7b..933b5bfc48 100644
--- a/configs/boston64r2el_defconfig
+++ b/configs/boston64r2el_defconfig
@@ -37,6 +37,7 @@ CONFIG_DM_ETH=y
 CONFIG_PCH_GBE=y
 CONFIG_PCI=y
 CONFIG_DM_PCI=y
+CONFIG_DM_PCI_BRIDGE_MEM_ALIGN=0x0
 CONFIG_PCI_XILINX=y
 CONFIG_SYS_NS16550=y
 CONFIG_LZ4=y
-- 
2.15.0



More information about the U-Boot mailing list