diff options
Diffstat (limited to 'DynamicTablesPkg/Include/ArchCommonNameSpaceObjects.h')
-rw-r--r--[-rwxr-xr-x] | DynamicTablesPkg/Include/ArchCommonNameSpaceObjects.h | 261 |
1 files changed, 256 insertions, 5 deletions
diff --git a/DynamicTablesPkg/Include/ArchCommonNameSpaceObjects.h b/DynamicTablesPkg/Include/ArchCommonNameSpaceObjects.h index 300f591..a642aec 100755..100644 --- a/DynamicTablesPkg/Include/ArchCommonNameSpaceObjects.h +++ b/DynamicTablesPkg/Include/ArchCommonNameSpaceObjects.h @@ -1,7 +1,7 @@ /** @file
Copyright (c) 2024, Arm Limited. All rights reserved.<BR>
- Copyright (c) 2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved.<BR>
+ Copyright (c) 2024 - 2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved.<BR>
Copyright (C) 2024 - 2025, Advanced Micro Devices, Inc. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
@@ -18,6 +18,7 @@ #include <AcpiObjects.h>
#include <StandardNameSpaceObjects.h>
+#include <IndustryStandard/AcpiAml.h>
#include <IndustryStandard/Tpm2Acpi.h>
/** The EARCH_COMMON_OBJECT_ID enum describes the Object IDs
@@ -59,6 +60,17 @@ typedef enum ArchCommonObjectID { EArchCommonObjPssInfo, ///< 32 - P-State status (PSS) Info
EArchCommonObjPpcInfo, ///< 33 - P-State control (PPC) Info
EArchCommonObjStaInfo, ///< 34 - _STA (Device Status) Info
+ EArchCommonObjMemoryRangeDescriptor, ///< 35 - Memory Range Descriptor
+ EArchCommonObjGenericDbg2DeviceInfo, ///< 36 - Generic DBG2 Device Info
+ EArchCommonObjCxlHostBridgeInfo, ///< 37 - CXL Host Bridge Info
+ EArchCommonObjCxlFixedMemoryWindowInfo, ///< 38 - CXL Fixed Memory Window Info
+ EArchCommonObjProximityDomainInfo, ///< 39 - Proximity Domain Info
+ EArchCommonObjProximityDomainRelationInfo, ///< 40 - Proximity Domain Relation Info
+ EArchCommonObjSystemLocalityInfo, ///< 41 - System Locality Info
+ EArchCommonObjMemoryProximityDomainAttrInfo, ///< 42 - Memory Proximity Domain Attribute
+ EArchCommonObjMemoryLatBwInfo, ///< 43 - Memory Latency Bandwidth Info
+ EArchCommonObjMemoryCacheInfo, ///< 44 - Memory Cache Info
+ EArchCommonObjSpcrInfo, ///< 45 - Serial Terminal and Interrupt Info
EArchCommonObjMax
} EARCH_COMMON_OBJECT_ID;
@@ -257,16 +269,22 @@ typedef struct CmArchCommonPciInterruptMapInfo { */
typedef struct CmArchCommonMemoryAffinityInfo {
/// The proximity domain to which the "range of memory" belongs.
- UINT32 ProximityDomain;
+ UINT32 ProximityDomain;
/// Base Address
- UINT64 BaseAddress;
+ UINT64 BaseAddress;
/// Length
- UINT64 Length;
+ UINT64 Length;
/// Flags
- UINT32 Flags;
+ UINT32 Flags;
+
+ /** Optional field: Reference Token to the ProximityDomain this object
+ belongs to. If set to CM_NULL_TOKEN, the following field is used:
+ CM_ARCH_COMMON_MEMORY_AFFINITY_INFO.ProximityDomain
+ */
+ CM_OBJECT_TOKEN ProximityDomainToken;
} CM_ARCH_COMMON_MEMORY_AFFINITY_INFO;
/** A structure that describes the ACPI Device Handle (Type 0) in the
@@ -317,6 +335,12 @@ typedef struct CmArchCommonGenericInitiatorAffinityInfo { /// Reference Token for the Device Handle
CM_OBJECT_TOKEN DeviceHandleToken;
+
+ /** Optional field: Reference Token to the ProximityDomain this object
+ belongs to. If set to CM_NULL_TOKEN, the following field is used:
+ CM_ARCH_COMMON_GENERIC_INITIATOR_AFFINITY_INFO.ProximityDomain
+ */
+ CM_OBJECT_TOKEN ProximityDomainToken;
} CM_ARCH_COMMON_GENERIC_INITIATOR_AFFINITY_INFO;
/** A structure that describes the Lpi information.
@@ -812,6 +836,233 @@ typedef struct CmArchCommonStaInfo { UINT32 DeviceStatus;
} CM_ARCH_COMMON_STA_INFO;
+/** A structure that describes the
+ Memory Range descriptor.
+
+ ID: EArchCommonObjMemoryRangeDescriptor
+*/
+typedef struct CmArchCommonMemoryRangeDescriptor {
+ /// Base address of Memory Range,
+ UINT64 BaseAddress;
+
+ /// Length of the Memory Range.
+ UINT64 Length;
+} CM_ARCH_COMMON_MEMORY_RANGE_DESCRIPTOR;
+
+/** A structure that describes a generic device to add a DBG2 device node from.
+
+ ID: EArchCommonObjGenericDbg2DeviceInfo,
+*/
+typedef struct CmArchCommonDbg2DeviceInfo {
+ /// Token identifying an array of CM_ARCH_COMMON_MEMORY_RANGE_DESCRIPTOR objects
+ CM_OBJECT_TOKEN AddressResourceToken;
+
+ /// The DBG2 port type
+ UINT16 PortType;
+
+ /// The DBG2 port subtype
+ UINT16 PortSubtype;
+
+ /// Access Size
+ UINT8 AccessSize;
+
+ /** ASCII Null terminated string that will be appended to \_SB_. for the full path.
+ */
+ CHAR8 ObjectName[AML_NAME_SEG_SIZE + 1];
+} CM_ARCH_COMMON_DBG2_DEVICE_INFO;
+
+/** A structure that describes a CXL Host Bridge Structure (Type 0).
+
+ ID: EArchCommonObjCxlHostBridgeInfo
+*/
+
+typedef struct CmArchCommonCxlHostBridgeInfo {
+ /// Token to identify this object.
+ CM_OBJECT_TOKEN Token;
+
+ /// Unique id to associate with a host bridge instance.
+ UINT32 Uid;
+
+ /// CXL version.
+ UINT32 Version;
+
+ /// Base address of the component registers.
+ UINT64 ComponentRegisterBase;
+} CM_ARCH_COMMON_CXL_HOST_BRIDGE_INFO;
+
+// Maximum interleave ways is defined in the CXL spec section 8.2.4.19.7.
+#define CFMWS_MAX_INTERLEAVE_WAYS (16)
+
+/** A structure that describes the CXL Fixed Memory Window Structure (Type 1).
+
+ ID: EArchCommonObjCxlFixedMemoryWindowInfo
+*/
+typedef struct CmArchCommonCxlFixedMemoryWindowInfo {
+ /// Base host physical address. Should be 256 MB aligned.
+ UINT64 BaseHostPhysicalAddress;
+
+ /// Size of the window in bytes. Should be 256 MB aligned.
+ UINT64 WindowSizeBytes;
+
+ /// Number of ways the memory region is interleaved.
+ UINT8 NumberOfInterleaveWays;
+
+ /// Interleave arithmetic method.
+ UINT8 InterleaveArithmetic;
+
+ /// Number of consecutive bytes per interleave.
+ UINT32 HostBridgeInterleaveGranularity;
+
+ /// Bit vector of window restriction settings.
+ UINT16 WindowRestrictions;
+
+ /// ID of Quality of Service Throttling Group for this window.
+ UINT16 QtgId;
+
+ /// Host bridge UIDs that are part of the interleave configuration.
+ /// The number of InterleaveTargetTokens is equal to NumberOfInterleaveWays.
+ /// Each array element identifies a CM_ARCH_COMMON_CXL_HOST_BRIDGE_INFO
+ /// structure via token matching.
+ CM_OBJECT_TOKEN InterleaveTargetTokens[CFMWS_MAX_INTERLEAVE_WAYS];
+} CM_ARCH_COMMON_CXL_FIXED_MEMORY_WINDOW_INFO;
+
+/** A structure that describes a proximity domain.
+
+ ID: EArchCommonObjProximityDomainInfo
+*/
+typedef struct CmArchCommonProximityDomainInfo {
+ /// GenerateDomainId
+ /// - TRUE if the DynamicTablesPkg framework should generate DomainId values.
+ /// - FALSE if CM_ARCH_COMMON_PROXIMITY_DOMAIN_INFO.DomainId should be used instead.
+ /// If GenerateDomainId is FALSE, user supplied DomainId values should be used.
+ /// Note: It is the user's responsibility to ensure that the DomainId values
+ /// are unique.
+ BOOLEAN GenerateDomainId;
+
+ /// DomainId.
+ /// Generators will use this DomainId if GenerateDomainId=FALSE.
+ UINT32 DomainId;
+} CM_ARCH_COMMON_PROXIMITY_DOMAIN_INFO;
+
+/** A structure that describes a relation between two proximity domains.
+
+ ID: EArchCommonObjProximityDomainRelationInfo
+*/
+typedef struct CmArchCommonProximityDomainRelationInfo {
+ /// First Domain Id Token.
+ /// Token referencing a CM_ARCH_COMMON_PROXIMITY_DOMAIN_INFO.
+ ///
+ /// For the HMAT sub-table of type 1 -
+ /// System Locality Latency and Bandwidth Information Structure
+ /// the First Domain is an Initiator Domain.
+ CM_OBJECT_TOKEN FirstDomainToken;
+
+ /// Second Domain Id Token.
+ /// Token referencing a CM_ARCH_COMMON_PROXIMITY_DOMAIN_INFO.
+ ///
+ /// For the HMAT sub-table of type 1 -
+ /// System Locality Latency and Bandwidth Information Structure
+ /// the Second Domain is a Target Domain.
+ CM_OBJECT_TOKEN SecondDomainToken;
+
+ /// Relation.
+ /// The meaning of this field depends on the object referencing this struct.
+ /// This could be a bandwidth, latency, relative distance (SLIT)...
+ UINT64 Relation;
+} CM_ARCH_COMMON_PROXIMITY_DOMAIN_RELATION_INFO;
+
+/** A structure that describes a relation between two proximity domains.
+
+ ID: EArchCommonObjSystemLocalityInfo
+*/
+typedef struct CmArchCommonSystemLocalityInfo {
+ /// Array of relative distances.
+ /// Token identifying an array of CM_ARCH_COMMON_DOMAIN_RELATION.
+ ///
+ /// If a relative distance between two domains is not provided,
+ /// the default value used is:
+ /// - 10 for the distance between a domain and itself, cf. the normalized
+ /// distance in the spec.
+ /// - 0xFF otherwise, i.e. the domains are unreachable from each other.
+ /// Relative distances must be > 10 for two different domains.
+ CM_OBJECT_TOKEN RelativeDistanceArray;
+} CM_ARCH_COMMON_SYSTEM_LOCALITY_INFO;
+
+/** A structure that describes the Memory Proximity Domain Attribute.
+
+ ID: EArchCommonObjMemoryProximityDomainAttrInfo
+*/
+typedef struct CmArchCommonMemoryProximityDomainAttrInfo {
+ /// Flags
+ UINT16 Flags;
+
+ /// Token referencing an Initiator Proximity Domain
+ /// I.e. a CM_ARCH_COMMON_PROXIMITY_DOMAIN_INFO
+ CM_OBJECT_TOKEN InitiatorProximityDomain;
+
+ /// Token referencing an Memory Proximity Domain
+ /// I.e. a CM_ARCH_COMMON_PROXIMITY_DOMAIN_INFO
+ CM_OBJECT_TOKEN MemoryProximityDomain;
+} CM_ARCH_COMMON_MEMORY_PROXIMITY_DOMAIN_ATTR_INFO;
+
+/** A structure that describes the Memory Latency Bandwidth Info.
+
+ ID: EArchCommonObjMemoryLatBwInfo
+*/
+typedef struct CmArchCommonMemoryLatBwInfo {
+ /// Flags
+ UINT8 Flags;
+
+ /// Data Type
+ UINT8 DataType;
+
+ /// Minimum Transfer Type
+ UINT8 MinTransferSize;
+
+ /// Entry Base Unit
+ UINT64 EntryBaseUnit;
+
+ /// Token referencing an array of CM_ARCH_COMMON_DOMAIN_RELATION_INFO
+ /// From this array, it is possible to retrieve:
+ /// - the number and Ids of the initiator domains
+ /// - the number and Ids of the target domains
+ /// - the latency/bandwidth between each domain
+ CM_OBJECT_TOKEN RelativeDistanceArray;
+} CM_ARCH_COMMON_MEMORY_LAT_BW_INFO;
+
+/** A structure that describes the Memory Cache Info.
+
+ ID: EArchCommonObjMemoryCacheInfo
+*/
+typedef struct CmArchCommonMemoryCacheInfo {
+ /// Token referencing a memory proximity domain.
+ CM_OBJECT_TOKEN MemoryProximityDomain;
+
+ /// Memory side cache size.
+ UINT64 MemorySideCacheSize;
+
+ /// Cache attributes.
+ UINT32 CacheAttributes;
+
+ /// @todo It is not possible to generate Smbios tables yet.
+ /// @todo Referencing Smbios tables is not possible for now,
+ /// @todo but will be in a near future.
+} CM_ARCH_COMMON_MEMORY_CACHE_INFO;
+
+/** A structure that describes the Serial Terminal and Interrupt Information.
+
+ This structure provides details about the interrupt type and terminal type
+ associated with a console device, used for the SPCR Table.
+
+ ID: EArchCommonObjSpcrInfo
+*/
+typedef struct CmArchCommonObjSpcrInfo {
+ /// Specifies the type of interrupt used by the console device.
+ UINT8 InterruptType;
+ /// Specifies the terminal type used by the console device.
+ UINT8 TerminalType;
+} CM_ARCH_COMMON_SPCR_INFO;
+
#pragma pack()
#endif // ARCH_COMMON_NAMESPACE_OBJECTS_H_
|