/** @file
Configurations for HostBridge
Copyright (c) 2021, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
#ifndef _HOST_BRIDGE_CONFIG_H_
#define _HOST_BRIDGE_CONFIG_H_
#include
#define HOST_BRIDGE_PREMEM_CONFIG_REVISION 1
#define HOST_BRIDGE_PEI_CONFIG_REVISION 1
extern EFI_GUID gHostBridgePeiPreMemConfigGuid;
extern EFI_GUID gHostBridgePeiConfigGuid;
#pragma pack (push,1)
/**
This configuration block describes HostBridge settings in PreMem.\n
Revision 1:
- Initial version.
**/
typedef struct {
CONFIG_BLOCK_HEADER Header; ///< Offset 0-27 Config Block Header
UINT32 MchBar; ///< Offset 28 Address of System Agent MCHBAR: 0xFEDC0000(TGL)/0xFED10000(RKL)/0xFEA80000(JSL)
UINT32 DmiBar; ///< Offset 32 Address of System Agent DMIBAR: 0xFEDA0000
UINT32 EpBar; ///< Offset 36 Address of System Agent EPBAR: 0xFEDA1000
UINT32 GdxcBar; ///< Offset 40 Address of System Agent GDXCBAR: 0xFED84000
UINT32 RegBar; ///< Offset 44 Address of System Agent REGBAR: 0xFB000000
UINT32 EdramBar; ///< Offset 48 Address of System Agent EDRAMBAR: 0xFED80000
/**
Offset 52 :
Size of reserved MMIO space for PCI devices\n
0=AUTO, 512=512MB, 768=768MB, 1024=1024MB, 1280=1280MB, 1536=1536MB, 1792=1792MB,
2048=2048MB, 2304=2304MB, 2560=2560MB, 2816=2816MB, 3072=3072MB\n
When AUTO mode selected, the MMIO size will be calculated by required MMIO size from PCIe devices detected.
**/
UINT32 MmioSize;
UINT32 MmioSizeAdjustment; ///< Offset 56 Increase (given positive value) or Decrease (given negative value) the Reserved MMIO size when Dynamic Tolud/AUTO mode enabled (in MBs): 0=no adjustment
UINT8 EnableAbove4GBMmio; ///< Offset 60 Enable/disable above 4GB MMIO resource support: 0=Disable, 1=Enable
UINT8 Reserved[3]; ///< Offset 61 Reserved for future use.
} HOST_BRIDGE_PREMEM_CONFIG;
/**
This configuration block describes HostBridge settings in Post-Mem.\n
Revision 1:
- Initial version.
**/
typedef struct {
CONFIG_BLOCK_HEADER Header; ///< Offset 0-27 Config Block Header
UINT8 Device4Enable; ///< Offser 28 :This policy is used to control enable or disable System Agent Thermal device (0,4,0). 0=FALSE, 1=TRUE.
UINT8 ChapDeviceEnable; ///< Offset 29 :(Test)This policy is used to control enable or disable System Agent Chap device (0,7,0). 0=FALSE, 1=TRUE.
UINT8 SkipPamLock; ///< Offset 30 :To skip PAM register locking. @note It is still recommended to set PCI Config space B0: D0: F0: Offset 80h[0]=1 in platform code even Silicon code skipped this.\n 0=All PAM registers will be locked in Silicon code, 1=Skip lock PAM registers in Silicon code.
UINT8 EdramTestMode; ///< Offset 28 :EDRAM Test Mode. For EDRAM stepping - 0- EDRAM SW Disable, 1- EDRAM SW Enable, 2- EDRAM HW Mode
} HOST_BRIDGE_PEI_CONFIG;
#pragma pack (pop)
#endif