Re: [edk2] [PATCH 2/2][platforms/dynamictables] Platform/ARM: Dynamic Tables support for FVP
> -Original Message- > From: Sami Mujawar [mailto:sami.muja...@arm.com] > Sent: 19 March 2018 15:22 > To: edk2-devel@lists.01.org > Cc: Arvind Chauhan; Daniil Egranov > ; Thomas Abraham > ; Evan Lloyd ; > leif.lindh...@linaro.org; Matteo Carlini ; > Stephanie Hughes-Fitt ; nd > > Subject: [PATCH 2/2][platforms/dynamictables] Platform/ARM: Dynamic > Tables support for FVP > > The dynamic tables framework utilizes the configuration manager protocol > to get the platform specific information required for building the firmware > tables. > > The configuration manager is a platform specific component that collates > the platform hardware information and builds an abstract platform > configuration repository. The configuration manager also implements the > configuration manager protocol which returns the hardware information > requested by the table generators. > > This patch implements the configuration manager support for the FVP > platform. > > The dynamic tables framework support is configurable and can be enabled > using the DYNAMIC_TABLES_FRAMEWORK build option. > > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Sami Mujawar Reviewed-by: Evan Lloyd > --- > Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc > | 15 + > Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf > | 16 +- > > Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManager. > dsc.inc| 31 + > > Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManager > Dxe/ConfigurationManager.c | 607 > > Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManager > Dxe/ConfigurationManager.h | 172 ++ > > Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManager > Dxe/ConfigurationManagerDxe.inf | 78 +++ > > Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManager > Dxe/Platform.h | 91 +++ > > Platform/ARM/VExpressPkg/ConfigurationManager/PlatformASLTablesLib/ > Dsdt.asl | 77 +++ > > Platform/ARM/VExpressPkg/ConfigurationManager/PlatformASLTablesLib/ > PlatformASLTablesLib.inf | 34 ++ > 9 files changed, 1119 insertions(+), 2 deletions(-) > > diff --git a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc > b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc > index > cdf9e2d49784d542701dc84eb511f592e77ec106..ed1a16b7b35d9854847e > 3898f8061abb5261e134 100644 > --- a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc > +++ b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc > @@ -38,6 +38,10 @@ [Defines] >DT_SUPPORT = FALSE > > !include Platform/ARM/VExpressPkg/ArmVExpress.dsc.inc > +!ifdef DYNAMIC_TABLES_FRAMEWORK > + !include DynamicTablesPkg/DynamicTables.dsc.inc > + !include > +Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManage > r.dsc. > +inc > +!endif > > [LibraryClasses.common] >ArmLib|ArmPkg/Library/ArmLib/ArmBaseLib.inf > @@ -128,6 +132,15 @@ [PcdsFixedAtBuild.common] >gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x1c09 >gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|115200 >gEfiMdePkgTokenSpaceGuid.PcdUartDefaultReceiveFifoDepth|0 > + gArmPlatformTokenSpaceGuid.PL011UartInterrupt|0x25 > + > + ## PL011 Serial Debug UART > + gArmPlatformTokenSpaceGuid.PcdSerialDbgRegisterBase|0x1c0a > + gArmPlatformTokenSpaceGuid.PcdSerialDbgUartBaudRate|115200 > + gArmPlatformTokenSpaceGuid.PcdSerialDbgUartClkInHz|2400 > + > + # SBSA Generic Watchdog > + gArmTokenSpaceGuid.PcdGenericWatchdogEl2IntrNum|59 > >## PL031 RealTimeClock >gArmPlatformTokenSpaceGuid.PcdPL031RtcBase|0x1C17 > @@ -255,8 +268,10 @@ [Components.common] !endif >} > > +!ifndef DYNAMIC_TABLES_FRAMEWORK >MdeModulePkg/Universal/Acpi/AcpiPlatformDxe/AcpiPlatformDxe.inf >Platform/ARM/VExpressPkg/AcpiTables/AcpiTables.inf > +!endif > >ArmPkg/Drivers/ArmGic/ArmGicDxe.inf >ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf > diff --git a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf > b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf > index > 305e661a2bdc3ade2c16232c77769df5fc6f0c32..db164be9641cf6e315302 > 3752f60f95909ce803c 100644 > --- a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf > +++ b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf > @@ -1,5 +1,5 @@ > # > -# Copyright (c) 2011 - 2015, ARM Limited. All rights reserved. > +# Copyright (c) 2011 - 2018, ARM Limited. All rights reserved. > # > # This program and the accompanying materials # are licensed and made > available under the terms and conditions of the BSD License @@ -97,9 > +97,19 @@ [FV.FvMain] > ># ACPI Support ># > - INF
[edk2] [PATCH 2/2][platforms/dynamictables] Platform/ARM: Dynamic Tables support for FVP
The dynamic tables framework utilizes the configuration manager protocol to get the platform specific information required for building the firmware tables. The configuration manager is a platform specific component that collates the platform hardware information and builds an abstract platform configuration repository. The configuration manager also implements the configuration manager protocol which returns the hardware information requested by the table generators. This patch implements the configuration manager support for the FVP platform. The dynamic tables framework support is configurable and can be enabled using the DYNAMIC_TABLES_FRAMEWORK build option. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Sami Mujawar--- Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc | 15 + Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf | 16 +- Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManager.dsc.inc | 31 + Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManagerDxe/ConfigurationManager.c | 607 Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManagerDxe/ConfigurationManager.h | 172 ++ Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManagerDxe/ConfigurationManagerDxe.inf | 78 +++ Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManagerDxe/Platform.h | 91 +++ Platform/ARM/VExpressPkg/ConfigurationManager/PlatformASLTablesLib/Dsdt.asl | 77 +++ Platform/ARM/VExpressPkg/ConfigurationManager/PlatformASLTablesLib/PlatformASLTablesLib.inf | 34 ++ 9 files changed, 1119 insertions(+), 2 deletions(-) diff --git a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc index cdf9e2d49784d542701dc84eb511f592e77ec106..ed1a16b7b35d9854847e3898f8061abb5261e134 100644 --- a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc +++ b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc @@ -38,6 +38,10 @@ [Defines] DT_SUPPORT = FALSE !include Platform/ARM/VExpressPkg/ArmVExpress.dsc.inc +!ifdef DYNAMIC_TABLES_FRAMEWORK + !include DynamicTablesPkg/DynamicTables.dsc.inc + !include Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManager.dsc.inc +!endif [LibraryClasses.common] ArmLib|ArmPkg/Library/ArmLib/ArmBaseLib.inf @@ -128,6 +132,15 @@ [PcdsFixedAtBuild.common] gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x1c09 gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|115200 gEfiMdePkgTokenSpaceGuid.PcdUartDefaultReceiveFifoDepth|0 + gArmPlatformTokenSpaceGuid.PL011UartInterrupt|0x25 + + ## PL011 Serial Debug UART + gArmPlatformTokenSpaceGuid.PcdSerialDbgRegisterBase|0x1c0a + gArmPlatformTokenSpaceGuid.PcdSerialDbgUartBaudRate|115200 + gArmPlatformTokenSpaceGuid.PcdSerialDbgUartClkInHz|2400 + + # SBSA Generic Watchdog + gArmTokenSpaceGuid.PcdGenericWatchdogEl2IntrNum|59 ## PL031 RealTimeClock gArmPlatformTokenSpaceGuid.PcdPL031RtcBase|0x1C17 @@ -255,8 +268,10 @@ [Components.common] !endif } +!ifndef DYNAMIC_TABLES_FRAMEWORK MdeModulePkg/Universal/Acpi/AcpiPlatformDxe/AcpiPlatformDxe.inf Platform/ARM/VExpressPkg/AcpiTables/AcpiTables.inf +!endif ArmPkg/Drivers/ArmGic/ArmGicDxe.inf ArmPlatformPkg/Drivers/NorFlashDxe/NorFlashDxe.inf diff --git a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf index 305e661a2bdc3ade2c16232c77769df5fc6f0c32..db164be9641cf6e3153023752f60f95909ce803c 100644 --- a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf +++ b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.fdf @@ -1,5 +1,5 @@ # -# Copyright (c) 2011 - 2015, ARM Limited. All rights reserved. +# Copyright (c) 2011 - 2018, ARM Limited. All rights reserved. # # This program and the accompanying materials # are licensed and made available under the terms and conditions of the BSD License @@ -97,9 +97,19 @@ [FV.FvMain] # ACPI Support # - INF MdeModulePkg/Universal/Acpi/AcpiPlatformDxe/AcpiPlatformDxe.inf INF MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableDxe.inf +!ifndef DYNAMIC_TABLES_FRAMEWORK + INF MdeModulePkg/Universal/Acpi/AcpiPlatformDxe/AcpiPlatformDxe.inf INF RuleOverride=ACPITABLE Platform/ARM/VExpressPkg/AcpiTables/AcpiTables.inf +!else + # Configuration Manager + INF Platform/ARM/VExpressPkg/ConfigurationManager/ConfigurationManagerDxe/ConfigurationManagerDxe.inf + + # + # Dynamic Table fdf + # + !include DynamicTablesPkg/DynamicTables.fdf.inc +!endif # # Multiple Console IO support @@ -319,8 +329,10 @@ [Rule.Common.UEFI_APPLICATION.BINARY] VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER) } +!ifndef