From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from EUR03-DB5-obe.outbound.protection.outlook.com (EUR03-DB5-obe.outbound.protection.outlook.com [40.107.4.49]) by mx.groups.io with SMTP id smtpd.web10.9721.1633702036421384186 for ; Fri, 08 Oct 2021 07:07:16 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=bdR716rt; spf=pass (domain: arm.com, ip: 40.107.4.49, mailfrom: sami.mujawar@arm.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=cgIZEssZkw0zs16HEltFVb3EJfv2Z2MhE60m4+wyuDs=; b=bdR716rtGMU4McYVI5+OKXIsmvS6fPsg2nY/nzYXiZ4eAL/S8YCYv8Gkb3puhioXb3L4WNh/QvJIKfhSYn3psIRRS5nLu/Xu0DMdtBXWIJpxerU77n1TgMIeL+SZ2UvyUgf0WZVkLb7lFtb/Z7VqL6x7K2KxnW9XhdG+ex/nOSs= Received: from AM5PR0601CA0047.eurprd06.prod.outlook.com (2603:10a6:203:68::33) by DB9PR08MB7115.eurprd08.prod.outlook.com (2603:10a6:10:2c8::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4587.18; Fri, 8 Oct 2021 14:07:14 +0000 Received: from AM5EUR03FT054.eop-EUR03.prod.protection.outlook.com (2603:10a6:203:68:cafe::b1) by AM5PR0601CA0047.outlook.office365.com (2603:10a6:203:68::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4587.18 via Frontend Transport; Fri, 8 Oct 2021 14:07:14 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; edk2.groups.io; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;edk2.groups.io; dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by AM5EUR03FT054.mail.protection.outlook.com (10.152.16.212) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4587.18 via Frontend Transport; Fri, 8 Oct 2021 14:07:13 +0000 Received: ("Tessian outbound d5def7722ff7:v103"); Fri, 08 Oct 2021 14:07:14 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 182ae88420dddbc6 X-CR-MTA-TID: 64aa7808 Received: from 5b865980f47f.2 by 64aa7808-outbound-1.mta.getcheckrecipient.com id F3881640-317D-442D-8A82-079CAF0248B0.1; Fri, 08 Oct 2021 14:07:08 +0000 Received: from EUR05-VI1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 5b865980f47f.2 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Fri, 08 Oct 2021 14:07:08 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RKWuNkMGEdjWDGT0Lleo+xcCo2qgtPyvf/Gh9UtazCFupIhChR78tIyPIss5rTeXfPVuNLj9efJ/bHY3hkGTtchZiq1dIlTnLAzOTrXznBG8DTmh6J8XpK32kMJMQQoFHwPd6Ro9LpFwgBaNjF+E8tGNGEHMkU3+YZ21e1nODWt9bgtXP/kxYTihXq+4Bl8rXxEXAo8XLitMlTDv6VWB1HcNxVyeElNUP7JDhqLnbXBbAKKntuBWXQEZ1dUEVO3sgH71MNkRL+dfZyFu7ou27dVuUg0I5iWkL/7KbymDILHUOBUZe4W2nRKV52asZ9vbjsD5l2JogPDqNbKmCYtDEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=cgIZEssZkw0zs16HEltFVb3EJfv2Z2MhE60m4+wyuDs=; b=Ur+A2F2GRTwtCaP2WGOV5FVnofyAGLEwt7ki6bzEa2jv0zEQUJl0wZ6xl8JXmX37tiS+N5/zi3nQ4bCQA1e65u1udCoC79MasEa7f0i44g5rK272+hB4ixu5IypOJQpEUBNYM9gS1GVswFjmbmpvjj5FMlPSu9qwVkK0RMWZtsdOB1XoEYvcEVBnAt1AoqPOLJ1jNZLMpfpsnH/I8m16V3R3ALWDdX7Rc9ll1DJpHdRUzvIJcYdoAMjwzu2s71XDR53S6ql1+lhszhtpPnCA0WsEDuZ+4f03Sz2ZNy0T3hOJbMddiHfs4HRnx9i4/j4vJvqE6FaidXrA3VWUphA7RA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=cgIZEssZkw0zs16HEltFVb3EJfv2Z2MhE60m4+wyuDs=; b=bdR716rtGMU4McYVI5+OKXIsmvS6fPsg2nY/nzYXiZ4eAL/S8YCYv8Gkb3puhioXb3L4WNh/QvJIKfhSYn3psIRRS5nLu/Xu0DMdtBXWIJpxerU77n1TgMIeL+SZ2UvyUgf0WZVkLb7lFtb/Z7VqL6x7K2KxnW9XhdG+ex/nOSs= Authentication-Results-Original: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=arm.com; Received: from AS8PR08MB6806.eurprd08.prod.outlook.com (2603:10a6:20b:39b::12) by AM6PR08MB3383.eurprd08.prod.outlook.com (2603:10a6:20b:50::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4566.22; Fri, 8 Oct 2021 14:07:06 +0000 Received: from AS8PR08MB6806.eurprd08.prod.outlook.com ([fe80::54b5:239d:9896:ee65]) by AS8PR08MB6806.eurprd08.prod.outlook.com ([fe80::54b5:239d:9896:ee65%4]) with mapi id 15.20.4587.022; Fri, 8 Oct 2021 14:07:06 +0000 Subject: Re: [PATCH v2 14/21] DynamicTablesPkg: AML code generation for a ResourceTemplate To: Pierre.Gondois@arm.com, devel@edk2.groups.io, Alexei.Fedorov@arm.com, nd References: <20211007153210.26608-1-Pierre.Gondois@arm.com> <20211007153210.26608-15-Pierre.Gondois@arm.com> From: "Sami Mujawar" Message-ID: <3e77d80d-05cf-e3d0-f1bc-bc4509a2aa18@arm.com> Date: Fri, 8 Oct 2021 15:07:12 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.0.1 In-Reply-To: <20211007153210.26608-15-Pierre.Gondois@arm.com> X-ClientProxiedBy: LO4P123CA0332.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:18c::13) To AS8PR08MB6806.eurprd08.prod.outlook.com (2603:10a6:20b:39b::12) MIME-Version: 1.0 Received: from [10.1.196.43] (217.140.106.52) by LO4P123CA0332.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:18c::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4566.19 via Frontend Transport; Fri, 8 Oct 2021 14:07:06 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 48e6b1e6-eef9-4b46-3936-08d98a64edcf X-MS-TrafficTypeDiagnostic: AM6PR08MB3383:|DB9PR08MB7115: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: x-checkrecipientrouted: true NoDisclaimer: true X-MS-Oob-TLC-OOBClassifiers: OLM:3968;OLM:6108; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: S1pK1awOboli5nJq4J2PIRijnSx0g8di9XtXseyiGBJ3o3yy5atdBXeIIXwwtFLZHVh8yVn0VJaLe3pGK3PyHAx2alwBsW363mUT0GRKxoqfAVHnf3YFi81a9As34ofDqT2+dvJ1rA/ebXGYgYRVA/pL9yvhr5ypSgofaMRKh2kHs5lqdACjEk1aTkUD4Q4ZC6SkUlWvSiwuRZvRNpweFp+vi+1Lw/zshhoaFnufJZTjKMsEkmyJDHU0KQl+izRqg2SgnWIvCuldvG/DUC/ChNySfi9F2JjAEmRjQB2JMclMaTPbY9HnG7mTbVEfqgNpYnP6lubHS0qRjsSziXuKuujteLdEvMQBcP8fY4EVKDkmqh3Tewtfq11TnUVlYuYRBNPmDL1y12HzGsDqpyeYr4ZeKMU10qX4ICPvzHfAGrozbBwVuOBKpkIBA1I/b2+Ckp5/ebrqp8tmLQpLvNYz0dRwycVCINnFBs1xXXnb6OVIqA+tJVJDKGLbCQPvZrZZbiTxQeIftjTh/6jRTfTntpt20ymNrUiI+sHB4KFCTUkjF970MqncQ+7LmacybfW3TyEiDw7mZNFEbopmLr7bO9pm+iG+Cy17fDlix8uXy1yug7tMwynYM3UZcj1XzoRx+uJVl+D+UG3zPDYxQmikOQwgeaH1Bh+XePV+8LoTw5z7s8fzFBClJiHgnFf7nP5XvhNni+0oYMLx9BtbT1xmv7ZnyOiZZVe6CuOhkz8hRilw/E0XRAW92URM8giJNKehMtz3tS2PiQ+KskV6Q6vT0g== X-Forefront-Antispam-Report-Untrusted: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AS8PR08MB6806.eurprd08.prod.outlook.com;PTR:;CAT:NONE;SFS:(4636009)(366004)(8936002)(86362001)(38100700002)(26005)(6862004)(38350700002)(6636002)(44832011)(508600001)(36756003)(53546011)(37006003)(316002)(16576012)(2616005)(66556008)(6486002)(5660300002)(186003)(66476007)(956004)(66946007)(52116002)(2906002)(8676002)(83380400001)(31686004)(31696002)(6666004)(45980500001)(43740500002);DIR:OUT;SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR08MB3383 Original-Authentication-Results: arm.com; dkim=none (message not signed) header.d=none;arm.com; dmarc=none action=none header.from=arm.com; Return-Path: Sami.Mujawar@arm.com X-EOPAttributedMessage: 0 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM5EUR03FT054.eop-EUR03.prod.protection.outlook.com X-MS-Office365-Filtering-Correlation-Id-Prvs: 29b2a0b6-a72c-43c6-35f4-08d98a64e951 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: tBwiVJMaLEmwfF4Sw7GISgXQue2mVJhN7eV7kBk732l91P795/oOG0RRd+OpdG0IeqhI4F6WodARJ9JBKMyiWX6C+CaeN40aXtfiClp9J9FteCpWprYU95M+eHYgPHGzxKnVIA03vFffgPvKYvH08KyVkxNC271ihbuHMwcD08ilOAUuyuux5GDpilLnTUPRwsNLg+3eH7WlPr/vRMWoUUVAjtJjXXP67kuC5YY0KdrVm+3X36c/wTy32juHBRRWVdnL9ZjxIcnlHN2C9Zjakrwnkc5y+aGEZvbbwvJ+IuhAbc8cB5ZgzG0o4BDWWKKjRvWP0xsSnOENjF4g0/uP3CIdEpPGncn+8Rzk03qTShxVLlzNOJ2RZUw7591/nA11cK+GPTlRarja62NEVetgpD1tN1BzDXI7d3yOVLQJqObY8JqAOYtjUgjXM+LEX51lXRndudkCGZBtsiFcCSEa2pApkyV5DYiWm2PsEuBoWpRaE9yH6/X7JNsFQs9tZhmqCsSvwP88DTQjrZLBV6wDPS++SwIZ82lIQmouY//bs7/snacMIaNtLnr0OTuwSD7PnawfHGNwU3/Ma8K2MEX7Rn2ybGNvpJff3duQHMljEAKFTFs3f1y+JvBaKjlltGMtrEVXdMzaYak5b8dWxh/TW75lWIg6HwsYNTs9UNS5kZBGAtJCdJXsTjCdVty+dTnvynQGqjFsqRsKuuasSiT88cIZMuwnbqRbyeIC6G5h42g= X-Forefront-Antispam-Report: CIP:63.35.35.123;CTRY:IE;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:64aa7808-outbound-1.mta.getcheckrecipient.com;PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com;CAT:NONE;SFS:(4636009)(46966006)(36840700001)(82310400003)(8936002)(5660300002)(47076005)(2906002)(70206006)(16576012)(53546011)(70586007)(26005)(37006003)(86362001)(31686004)(6666004)(316002)(6862004)(6636002)(83380400001)(356005)(186003)(81166007)(6486002)(44832011)(31696002)(2616005)(956004)(508600001)(36756003)(36860700001)(336012)(8676002)(43740500002);DIR:OUT;SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Oct 2021 14:07:13.9949 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 48e6b1e6-eef9-4b46-3936-08d98a64edcf X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d;Ip=[63.35.35.123];Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: AM5EUR03FT054.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9PR08MB7115 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Content-Language: en-GB Hi Pierre, Thank you for this patch. Reviewed-by: Sami Mujawar Regards, Sami Mujawar On 07/10/2021 04:32 PM, Pierre.Gondois@arm.com wrote: > From: Pierre Gondois > > ASL provides a ResourceTemplate macro that creates a Buffer in which > resource descriptor macros can be listed. The ResourceTemplate macro > automatically generates an End descriptor and calculates the checksum > for the resource template. > > Therefore, add AmlCodeGenResourceTemplate() to generate AML code for > the ResourceTemplate() macro. This function generates a Buffer node > with an EndTag resource data descriptor, which is similar to the ASL > ResourceTemplate() macro. > > Signed-off-by: Pierre Gondois > --- > .../Common/AmlLib/CodeGen/AmlCodeGen.c | 190 ++++++++++++++++++ > 1 file changed, 190 insertions(+) > > diff --git a/DynamicTablesPkg/Library/Common/AmlLib/CodeGen/AmlCodeGen.c = b/DynamicTablesPkg/Library/Common/AmlLib/CodeGen/AmlCodeGen.c > index a4cd2502dc56..da80e9d77cc2 100644 > --- a/DynamicTablesPkg/Library/Common/AmlLib/CodeGen/AmlCodeGen.c > +++ b/DynamicTablesPkg/Library/Common/AmlLib/CodeGen/AmlCodeGen.c > @@ -12,6 +12,7 @@ > > #include > #include > +#include > #include > #include > #include > @@ -316,6 +317,195 @@ error_handler: > return Status; > } > > +/** AML code generation for a Buffer object node. > + > + To create a Buffer object node with an empty buffer, > + call the function with (Buffer=3DNULL, BufferSize=3D0). > + > + @param [in] Buffer Buffer to set for the created Buffer > + object node. The Buffer's content is copi= ed. > + NULL if there is no buffer to set for > + the Buffer node. > + @param [in] BufferSize Size of the Buffer. > + 0 if there is no buffer to set for > + the Buffer node. > + @param [out] NewObjectNode If success, contains the created > + Buffer object node. > + > + @retval EFI_SUCCESS Success. > + @retval EFI_INVALID_PARAMETER Invalid parameter. > + @retval EFI_OUT_OF_RESOURCES Failed to allocate memory. > +**/ > +STATIC > +EFI_STATUS > +EFIAPI > +AmlCodeGenBuffer ( > + IN CONST UINT8 * Buffer, OPTIONAL > + IN UINT32 BufferSize, OPTIONAL > + OUT AML_OBJECT_NODE ** NewObjectNode > + ) > +{ > + EFI_STATUS Status; > + AML_OBJECT_NODE * BufferNode; > + AML_OBJECT_NODE * BufferSizeNode; > + UINT32 BufferSizeNodeSize; > + AML_DATA_NODE * DataNode; > + UINT32 PkgLen; > + > + // Buffer and BufferSize must be either both set, or both clear. > + if ((NewObjectNode =3D=3D NULL) || > + ((Buffer =3D=3D NULL) !=3D (BufferSize =3D=3D 0))) { > + ASSERT (0); > + return EFI_INVALID_PARAMETER; > + } > + > + BufferNode =3D NULL; > + DataNode =3D NULL; > + > + // Cf ACPI 6.3 specification, s20.2.5.4 "Type 2 Opcodes Encoding" > + // DefBuffer :=3D BufferOp PkgLength BufferSize ByteList > + // BufferOp :=3D 0x11 > + // BufferSize :=3D TermArg =3D> Integer > + > + Status =3D AmlCodeGenInteger (BufferSize, &BufferSizeNode); > + if (EFI_ERROR (Status)) { > + ASSERT (0); > + return Status; > + } > + > + // Get the number of bytes required to encode the BufferSizeNode. > + Status =3D AmlComputeSize ( > + (AML_NODE_HEADER*)BufferSizeNode, > + &BufferSizeNodeSize > + ); > + if (EFI_ERROR (Status)) { > + ASSERT (0); > + goto error_handler; > + } > + > + // Compute the size to write in the PkgLen. > + Status =3D AmlComputePkgLength (BufferSizeNodeSize + BufferSize, &PkgL= en); > + if (EFI_ERROR (Status)) { > + ASSERT (0); > + goto error_handler; > + } > + > + // Create an object node for the buffer. > + Status =3D AmlCreateObjectNode ( > + AmlGetByteEncodingByOpCode (AML_BUFFER_OP, 0), > + PkgLen, > + &BufferNode > + ); > + if (EFI_ERROR (Status)) { > + ASSERT (0); > + goto error_handler; > + } > + > + // Set the BufferSizeNode as a fixed argument of the BufferNode. > + Status =3D AmlSetFixedArgument ( > + BufferNode, > + EAmlParseIndexTerm0, > + (AML_NODE_HEADER*)BufferSizeNode > + ); > + if (EFI_ERROR (Status)) { > + ASSERT (0); > + goto error_handler; > + } > + > + // BufferSizeNode is now attached. > + BufferSizeNode =3D NULL; > + > + // If there is a buffer, create a DataNode and attach it to the Buffer= Node. > + if (Buffer !=3D NULL) { > + Status =3D AmlCreateDataNode ( > + EAmlNodeDataTypeRaw, > + Buffer, > + BufferSize, > + &DataNode > + ); > + if (EFI_ERROR (Status)) { > + ASSERT (0); > + goto error_handler; > + } > + > + Status =3D AmlVarListAddTail ( > + (AML_NODE_HEADER*)BufferNode, > + (AML_NODE_HEADER*)DataNode > + ); > + if (EFI_ERROR (Status)) { > + ASSERT (0); > + goto error_handler; > + } > + } > + > + *NewObjectNode =3D BufferNode; > + return Status; > + > +error_handler: > + if (BufferSizeNode !=3D NULL) { > + AmlDeleteTree ((AML_NODE_HEADER*)BufferSizeNode); > + } > + if (BufferNode !=3D NULL) { > + AmlDeleteTree ((AML_NODE_HEADER*)BufferNode); > + } > + if (DataNode !=3D NULL) { > + AmlDeleteTree ((AML_NODE_HEADER*)DataNode); > + } > + return Status; > +} > + > +/** AML code generation for a ResourceTemplate. > + > + "ResourceTemplate" is a macro defined in ACPI 6.3, s19.3.3 > + "ASL Resource Templates". It allows to store resource data elements. > + > + In AML, a ResourceTemplate is implemented as a Buffer storing resource > + data elements. An EndTag resource data descriptor must be at the end > + of the list of resource data elements. > + This function generates a Buffer node with an EndTag resource data > + descriptor. It can be seen as an empty list of resource data elements. > + > + @param [out] NewObjectNode If success, contains the created > + ResourceTemplate object node. > + > + @retval EFI_SUCCESS Success. > + @retval EFI_INVALID_PARAMETER Invalid parameter. > + @retval EFI_OUT_OF_RESOURCES Failed to allocate memory. > +**/ > +STATIC > +EFI_STATUS > +EFIAPI > +AmlCodeGenResourceTemplate ( > + OUT AML_OBJECT_NODE ** NewObjectNode > + ) > +{ > + EFI_STATUS Status; > + AML_OBJECT_NODE * BufferNode; > + > + if (NewObjectNode =3D=3D NULL) { > + ASSERT (0); > + return EFI_INVALID_PARAMETER; > + } > + > + // Create a BufferNode with an empty buffer. > + Status =3D AmlCodeGenBuffer (NULL, 0, &BufferNode); > + if (EFI_ERROR (Status)) { > + ASSERT (0); > + return Status; > + } > + > + // Create an EndTag resource data element and attach it to the Buffer. > + Status =3D AmlCodeGenEndTag (0, BufferNode, NULL); > + if (EFI_ERROR (Status)) { > + ASSERT (0); > + AmlDeleteTree ((AML_NODE_HEADER*)BufferNode); > + return Status; > + } > + > + *NewObjectNode =3D BufferNode; > + return Status; > +} > + > /** AML code generation for a Name object node. > > @param [in] NameString The new variable name. IMPORTANT NOTICE: The contents of this email and any attachments are confid= ential and may also be privileged. If you are not the intended recipient, p= lease notify the sender immediately and do not disclose the contents to any= other person, use it for any purpose, or store or copy the information in = any medium. Thank you.