From 0dacb43505df060f1005edab6c2a6bcf69c18acb Mon Sep 17 00:00:00 2001 From: Sami Mujawar Date: Wed, 14 Feb 2024 10:06:54 +0000 Subject: [PATCH] DynamicTablesPkg: Introduce an Arch Common Namespace Introduce an Arch Common Namespace so that the common architectural objects can be defined under this namespace in the Configuration manager. Also rearrange the namespace IDs so that the Arch Common Namespace has a value of 0x1, the Arm Namespace ID has a value of 0x2, and the Custom/OEM namespace ID has a value of 0xF. Also introduce a helper macro to create configuration manager objects in the Arch Common Namespace. The Arch Common Namespace shall contain objects like Serial Port, PCI Bus information etc. It must not contain Architecture specific components e.g. GICC which is Arm architecture specific component and therefore must be defined in the Arm Namespace. Cc: Pierre Gondois Cc: Yeo Reum Yun Cc: AbdulLateef Attar Cc: Jeshua Smith Cc: Jeff Brasen Cc: Girish Mahadevan Cc: Leif Lindholm Cc: Meenakshi Aggarwal Signed-off-by: Sami Mujawar Reviewed-by: Sunil V L --- .../Include/ConfigurationManagerObject.h | 26 +++-- DynamicTablesPkg/Readme.md | 97 +++++++++++++++++++ 2 files changed, 116 insertions(+), 7 deletions(-) diff --git a/DynamicTablesPkg/Include/ConfigurationManagerObject.h b/DynamicTablesPkg/Include/ConfigurationManagerObject.h index 74ad25d5d9..4255c82b42 100644 --- a/DynamicTablesPkg/Include/ConfigurationManagerObject.h +++ b/DynamicTablesPkg/Include/ConfigurationManagerObject.h @@ -1,6 +1,6 @@ /** @file - Copyright (c) 2017 - 2022, ARM Limited. All rights reserved. + Copyright (c) 2017 - 2024, Arm Limited. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent @@ -29,8 +29,9 @@ _______________________________________________________________________________ Bits: [31:28] - Name Space ID 0000 - Standard - 0001 - ARM - 1000 - Custom/OEM + 0001 - Arch Common + 0010 - ARM + 1111 - Custom/OEM All other values are reserved. Bits: [27:16] - Reserved. @@ -105,10 +106,11 @@ typedef UINT32 CM_OBJECT_ID; for the Configuration Manager Objects. */ typedef enum ObjectNameSpaceID { - EObjNameSpaceStandard, ///< Standard Objects Namespace - EObjNameSpaceArm, ///< ARM Objects Namespace - EObjNameSpaceOem = 0x8, ///< OEM Objects Namespace - EObjNameSpaceMax + EObjNameSpaceStandard, ///< Standard Objects Namespace + EObjNameSpaceArchCommon, ///< Arch Common Objects Namespace + EObjNameSpaceArm, ///< ARM Objects Namespace + EObjNameSpaceOem = 0xF, ///< OEM Objects Namespace + EObjNameSpaceMax, } EOBJECT_NAMESPACE_ID; /** A descriptor for Configuration Manager Objects. @@ -182,6 +184,16 @@ typedef struct CmObjDescriptor { #define CREATE_CM_ARM_OBJECT_ID(ObjectId) \ (CREATE_CM_OBJECT_ID (EObjNameSpaceArm, ObjectId)) +/** This macro returns a Configuration Manager Object ID + in the Arch Common Object Namespace. + + @param [in] ObjectId The Object ID. + + @retval Returns an Arch Common Configuration Manager Object ID. +**/ +#define CREATE_CM_ARCH_COMMON_OBJECT_ID(ObjectId) \ + (CREATE_CM_OBJECT_ID (EObjNameSpaceArchCommon, ObjectId)) + /** This macro returns a Configuration Manager Object ID in the OEM Object Namespace. diff --git a/DynamicTablesPkg/Readme.md b/DynamicTablesPkg/Readme.md index c1cdc5e173..1ae423af75 100644 --- a/DynamicTablesPkg/Readme.md +++ b/DynamicTablesPkg/Readme.md @@ -402,3 +402,100 @@ Refer to the following presentation from *UEFI Plugfest Seattle 2018*: [Dynamic Tables Framework: A Step Towards Automatic Generation of Advanced Configuration and Power Interface (ACPI) & System Management BIOS (SMBIOS) Tables](http://www.uefi.org/sites/default/files/resources/Arm_Dynamic%20Tables%20Framework%20A%20Step%20Towards%20Automatic%20Generation%20of%20Advanced%20Configuration%20and%20Power%20Interface%20%28ACPI%29%20%26%20System%20Management%20BIOS%20%28SMBIOS%29%20Tables%20_0.pdf) +## Configuration Manager Objects + +The CM_OBJECT_ID type is used to identify the Configuration Manager + objects. + +## Description of Configuration Manager Object ID + +| 31 - 28 | 27 - 8 | 7 - 0 | +| :-------------: | :----: | :---------: | +| `Name Space ID` | 0 | `Object ID` | +------------------------------------------ + +### Name Space ID: Bits [31:28] + +| ID | Description | Comments | +| ---: | :-------------------------- | :--- | +| 0000b | Standard | | +| 0001b | Arch Common | | +| 0010b | ARM | | +| 1111b | Custom/OEM | | +| `*` | All other values are reserved. | | + +### Bits: [27:8] - Reserved, must be zero. + +### Bits: [7:0] - Object ID + +#### Object ID's in the Standard Namespace: + +| ID | Description | Comments | +| ---: | :-------------------------- | :--- | +| 0 | Configuration Manager Revision | | +| 1 | ACPI Table List | | +| 2 | SMBIOS Table List | | + +#### Object ID's in the ARM Namespace: + +| ID | Description | Comments | +| ---: | :-------------------------- | :--- | +| 0 | Reserved | | +| 1 | Boot Architecture Info | | +| 2 | CPU Info | | +| 3 | Power Management Profile Info | | +| 4 | GICC Info | | +| 5 | GICD Info | | +| 6 | GIC MSI Frame Info | | +| 7 | GIC Redistributor Info | | +| 8 | GIC ITS Info | | +| 9 | Serial Console Port Info | | +| 10 | Serial Debug Port Info | | +| 11 | Generic Timer Info | | +| 12 | Platform GT Block Info | | +| 13 | Generic Timer Block Frame Info | | +| 14 | Platform Generic Watchdog | | +| 15 | PCI Configuration Space Info | | +| 16 | Hypervisor Vendor Id | | +| 17 | Fixed feature flags for FADT | | +| 18 | ITS Group | | +| 19 | Named Component | | +| 20 | Root Complex | | +| 21 | SMMUv1 or SMMUv2 | | +| 22 | SMMUv3 | | +| 23 | PMCG | | +| 24 | GIC ITS Identifier Array | | +| 25 | ID Mapping Array | | +| 26 | SMMU Interrupt Array | | +| 27 | Processor Hierarchy Info | | +| 28 | Cache Info | | +| 29 | Reserved29 | | +| 30 | CM Object Reference | | +| 31 | Memory Affinity Info | | +| 32 | Device Handle Acpi | | +| 33 | Device Handle PCI | | +| 34 | Generic Initiator Affinity Info | | +| 35 | Serial Port Info | | +| 36 | CMN 600 Info | | +| 37 | Low Power Idle State Info | | +| 38 | PCI Address Map Info | | +| 39 | PCI Interrupt Map Info | | +| 40 | Reserved Memory Range Node | | +| 41 | Memory Range Descriptor | | +| 42 | Continuous Performance Control Info | | +| 43 | Pcc Subspace Type 0 Info | | +| 44 | Pcc Subspace Type 1 Info | | +| 45 | Pcc Subspace Type 2 Info | | +| 46 | Pcc Subspace Type 3 Info | | +| 47 | Pcc Subspace Type 4 Info | | +| 48 | Pcc Subspace Type 5 Info | | +| 49 | Embedded Trace Extension/Module Info | | +| 50 | P-State Dependency (PSD) Info | | +| `*` | All other values are reserved. | | + +#### Object ID's in the Arch Common Namespace: + +| ID | Description | Comments | +| ---: | :-------------------------- | :--- | +| 0 | Reserved | | +| `*` | All other values are reserved. | |