]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdePkg/MdeModulePkg: Move AML_NAME_SEG_SIZE definition
authorPierre Gondois <Pierre.Gondois@arm.com>
Tue, 1 Jun 2021 22:04:49 +0000 (23:04 +0100)
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Wed, 2 Jun 2021 09:57:17 +0000 (09:57 +0000)
A NameSeg is made 4 chars.
Cf. ACPI 6.4 s20.2.2 "Name Objects Encoding":
NameSeg := <leadnamechar namechar namechar namechar>
Notice that NameSegs shorter than 4 characters are filled
with trailing underscores (‘_’s).

AML_NAME_SEG_SIZE is currently defined in:
- DynamicTablesPkg/Library/Common/AmlLib/AmlDefines.h
- MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiSdt.h
Since the value can be inferred from the ACPI specification
and to avoid multiple definitions, move it to
MdePkg/Include/IndustryStandard/

Signed-off-by: Pierre Gondois <Pierre.Gondois@arm.com>
Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
Reviewed-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Sami Mujawar <sami.mujawar@arm.com>
MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiSdt.h
MdePkg/Include/IndustryStandard/AcpiAml.h

index 50d4c96edb6365da0550cfcfb11871bb1b890988..1b26729e71c3c22cf7a04e0da337ff80f4b2a297 100644 (file)
@@ -56,7 +56,6 @@ typedef struct _EFI_AML_NODE_LIST EFI_AML_NODE_LIST;
 //  Size is the total size of this ACPI node buffer.\r
 //  Children is the children linked list of this node.\r
 //\r
-#define AML_NAME_SEG_SIZE  4\r
 \r
 struct _EFI_AML_NODE_LIST {\r
   UINT32                  Signature;\r
index 74622e912ea42c2a04379362843473cac5ea5856..4255ca3d7087518ec84780a10a4bf4c2ceb97648 100644 (file)
@@ -2,7 +2,7 @@
   This file contains AML code definition in the latest ACPI spec.\r
 \r
   Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>\r
-  Copyright (c) 2019, ARM Limited. All rights reserved.<BR>\r
+  Copyright (c) 2019 - 2021, Arm Limited. All rights reserved.<BR>\r
   SPDX-License-Identifier: BSD-2-Clause-Patent\r
 \r
 **/\r
 #define AML_FIELD_CONNECTION_OP      0x02\r
 #define AML_FIELD_EXT_ACCESS_OP      0x03\r
 \r
+//\r
+// AML Name segment definitions\r
+//\r
+#define AML_NAME_SEG_SIZE            4\r
+\r
 #endif\r