diff mbox

[edk2,v7,14/24] ArmVirtualizationPkg: introduce PCDs for device tree base address

Message ID 1409918214-29584-15-git-send-email-ard.biesheuvel@linaro.org
State New
Headers show

Commit Message

Ard Biesheuvel Sept. 5, 2014, 11:56 a.m. UTC
Introduce gArmVirtualizationTokenSpaceGuid.PcdDeviceTreeBaseAddress and
PcdDeviceTreeInitialBaseAddress, which will be used by virtual machine ports
that discover the system configuration from a flattened device tree DTB image.

The latter is FixedPcd only, and should contain the initial offset of the DTB,
the former may be declared as dynamic, and updated at runtime if the DTB is
relocated before the DXE phase.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
---
 .../ArmVirtualizationPkg/ArmVirtualizationPkg.dec  | 46 ++++++++++++++++++++++
 1 file changed, 46 insertions(+)
 create mode 100644 ArmPlatformPkg/ArmVirtualizationPkg/ArmVirtualizationPkg.dec

Comments

Laszlo Ersek Sept. 6, 2014, 8:55 p.m. UTC | #1
On 09/05/14 13:56, Ard Biesheuvel wrote:
> Introduce gArmVirtualizationTokenSpaceGuid.PcdDeviceTreeBaseAddress and
> PcdDeviceTreeInitialBaseAddress, which will be used by virtual machine ports
> that discover the system configuration from a flattened device tree DTB image.
> 
> The latter is FixedPcd only, and should contain the initial offset of the DTB,
> the former may be declared as dynamic, and updated at runtime if the DTB is
> relocated before the DXE phase.
> 
> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> ---
>  .../ArmVirtualizationPkg/ArmVirtualizationPkg.dec  | 46 ++++++++++++++++++++++
>  1 file changed, 46 insertions(+)
>  create mode 100644 ArmPlatformPkg/ArmVirtualizationPkg/ArmVirtualizationPkg.dec
> 
> diff --git a/ArmPlatformPkg/ArmVirtualizationPkg/ArmVirtualizationPkg.dec b/ArmPlatformPkg/ArmVirtualizationPkg/ArmVirtualizationPkg.dec
> new file mode 100644
> index 000000000000..8d51182d716b
> --- /dev/null
> +++ b/ArmPlatformPkg/ArmVirtualizationPkg/ArmVirtualizationPkg.dec
> @@ -0,0 +1,46 @@
> +#/** @file
> +#
> +#  Copyright (c) 2014, Linaro Limited. All rights reserved.
> +#
> +#  This program and the accompanying materials
> +#  are licensed and made available under the terms and conditions of the BSD License
> +#  which accompanies this distribution.  The full text of the license may be found at
> +#  http://opensource.org/licenses/bsd-license.php
> +#
> +#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
> +#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
> +#
> +#**/
> +
> +[Defines]
> +  DEC_SPECIFICATION              = 0x00010005
> +  PACKAGE_NAME                   = ArmVirtualizationPkg
> +  PACKAGE_GUID                   = A0B31216-508E-4025-BEAB-56D836C66F0A
> +  PACKAGE_VERSION                = 0.1
> +
> +################################################################################
> +#
> +# Include Section - list of Include Paths that are provided by this package.
> +#                   Comments are used for Keywords and Module Types.
> +#
> +# Supported Module Types:
> +#  BASE SEC PEI_CORE PEIM DXE_CORE DXE_DRIVER DXE_RUNTIME_DRIVER DXE_SMM_DRIVER DXE_SAL_DRIVER UEFI_DRIVER UEFI_APPLICATION
> +#
> +################################################################################
> +[Includes.common]
> +  Include                        # Root include for the package
> +
> +[Guids.common]
> +  gArmVirtualizationTokenSpaceGuid = { 0x0B6F5CA7, 0x4F53, 0x445A, { 0xB7, 0x6E, 0x2E, 0x36, 0x5B, 0x80, 0x63, 0x66 } }
> +
> +[PcdsFixedAtBuild]
> +  #
> +  # This is the physical address where the device tree is expected to be stored
> +  # upon first entry into UEFI. This needs to be a FixedAtBuild PCD, so that we
> +  # can do a first pass over the device tree in the SEC phase to discover the
> +  # UART base address.
> +  #
> +  gArmVirtualizationTokenSpaceGuid.PcdDeviceTreeInitialBaseAddress|0x0|UINT64|0x00000001
> +
> +[PcdsDynamic,PcdsFixedAtBuild]
> +  gArmVirtualizationTokenSpaceGuid.PcdDeviceTreeBaseAddress|0x0|UINT64|0x00000002
> 

Reviewed-by: Laszlo Ersek <lersek@redhat.com>

------------------------------------------------------------------------------
Slashdot TV.  
Video for Nerds.  Stuff that matters.
http://tv.slashdot.org/
diff mbox

Patch

diff --git a/ArmPlatformPkg/ArmVirtualizationPkg/ArmVirtualizationPkg.dec b/ArmPlatformPkg/ArmVirtualizationPkg/ArmVirtualizationPkg.dec
new file mode 100644
index 000000000000..8d51182d716b
--- /dev/null
+++ b/ArmPlatformPkg/ArmVirtualizationPkg/ArmVirtualizationPkg.dec
@@ -0,0 +1,46 @@ 
+#/** @file
+#
+#  Copyright (c) 2014, Linaro Limited. All rights reserved.
+#
+#  This program and the accompanying materials
+#  are licensed and made available under the terms and conditions of the BSD License
+#  which accompanies this distribution.  The full text of the license may be found at
+#  http://opensource.org/licenses/bsd-license.php
+#
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
+#**/
+
+[Defines]
+  DEC_SPECIFICATION              = 0x00010005
+  PACKAGE_NAME                   = ArmVirtualizationPkg
+  PACKAGE_GUID                   = A0B31216-508E-4025-BEAB-56D836C66F0A
+  PACKAGE_VERSION                = 0.1
+
+################################################################################
+#
+# Include Section - list of Include Paths that are provided by this package.
+#                   Comments are used for Keywords and Module Types.
+#
+# Supported Module Types:
+#  BASE SEC PEI_CORE PEIM DXE_CORE DXE_DRIVER DXE_RUNTIME_DRIVER DXE_SMM_DRIVER DXE_SAL_DRIVER UEFI_DRIVER UEFI_APPLICATION
+#
+################################################################################
+[Includes.common]
+  Include                        # Root include for the package
+
+[Guids.common]
+  gArmVirtualizationTokenSpaceGuid = { 0x0B6F5CA7, 0x4F53, 0x445A, { 0xB7, 0x6E, 0x2E, 0x36, 0x5B, 0x80, 0x63, 0x66 } }
+
+[PcdsFixedAtBuild]
+  #
+  # This is the physical address where the device tree is expected to be stored
+  # upon first entry into UEFI. This needs to be a FixedAtBuild PCD, so that we
+  # can do a first pass over the device tree in the SEC phase to discover the
+  # UART base address.
+  #
+  gArmVirtualizationTokenSpaceGuid.PcdDeviceTreeInitialBaseAddress|0x0|UINT64|0x00000001
+
+[PcdsDynamic,PcdsFixedAtBuild]
+  gArmVirtualizationTokenSpaceGuid.PcdDeviceTreeBaseAddress|0x0|UINT64|0x00000002