Marvell: Armada7k8k/OcteonTx: Allow tuning PCIE config space size

Until now it was assumed that the configuration space size is 256MB.
Allow setting different values in the board description library
instance for each platform.

Signed-off-by: Marcin Wojtas <mw@semihalf.com>
This commit is contained in:
Marcin Wojtas
2021-07-25 14:55:37 +02:00
parent 1167b72de9
commit 237888287c
2 changed files with 4 additions and 1 deletions

View File

@@ -141,7 +141,9 @@ ArmPlatformGetVirtualMemoryMap (
for (PcieIndex = 0; PcieIndex < PcieControllerCount; PcieIndex++) {
mVirtualMemoryTable[++Index].PhysicalBase = PcieControllers[PcieIndex].ConfigSpaceAddress;
mVirtualMemoryTable[Index].VirtualBase = PcieControllers[PcieIndex].ConfigSpaceAddress;
mVirtualMemoryTable[Index].Length = SIZE_256MB;
mVirtualMemoryTable[Index].Length = (PcieControllers[PcieIndex].ConfigSpaceSize == 0) ?
SIZE_256MB :
PcieControllers[PcieIndex].ConfigSpaceSize;
mVirtualMemoryTable[Index].Attributes = ARM_MEMORY_REGION_ATTRIBUTE_DEVICE;
}

View File

@@ -111,6 +111,7 @@ typedef struct {
typedef struct {
EFI_PHYSICAL_ADDRESS PcieDbiAddress;
EFI_PHYSICAL_ADDRESS ConfigSpaceAddress;
UINT64 ConfigSpaceSize;
BOOLEAN HaveResetGpio;
MV_GPIO_PIN PcieResetGpio;
UINT64 PcieBusMin;