From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2607:f8b0:4864:20::d44; helo=mail-io1-xd44.google.com; envelope-from=ard.biesheuvel@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-io1-xd44.google.com (mail-io1-xd44.google.com [IPv6:2607:f8b0:4864:20::d44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 3A65C2194D387 for ; Tue, 22 Jan 2019 01:22:08 -0800 (PST) Received: by mail-io1-xd44.google.com with SMTP id m19so18564635ioh.3 for ; Tue, 22 Jan 2019 01:22:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=jvp/t1qv6oRqH+KVuIoctFtrRT0XKi6ORcjuKnHO/lM=; b=FzbJY0K4PstLJ0fNzJPoRcCGSzUM+o9IVcqx/5oViEqIAO2S4qL9BE1tR9ny2CbpGt iyXixdsRzPok4krGY2+euKniGCIYxu2ddATdfEISJm4NvKcQu7hjtVEGaaz+ASL9ygJn NTxZQBzn3VD2MPH5+mnamhFyTPZMQaiyLiwgM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=jvp/t1qv6oRqH+KVuIoctFtrRT0XKi6ORcjuKnHO/lM=; b=APnK00Es8T7xwt7QzfSYLpfXw8t49/gNKCbMIfcF04EAj3XAJoPz8XywbZkUZblwoM WGfdPtbvOarqag5G0E1AHRLYfsrPCxBA6+l2p3IqKncKOiAgImr89u82IhYKf5CsvJ0C a2CcKydtaeknkDGLhyOtKgkBq7Bpy0/s9iaHrqVBPq25n4z0FEqqFP5BMz0WYOWeVS6l jWSmta3rONtJHFtUf7XeLeVz3q6QI16tzU4K2EPkVPEtFOok2GwMYou2/pMoNJz1vd5S yQLLXPgDv8ks9dIv8c5ir6Ufo3Xg2XGpHD1UrRPiSyoU1tJKT/omTL3gUL1DKQUSnH2A ZI+w== X-Gm-Message-State: AJcUukdjLahWcUTpklQtpi6CGRi58ksJgoNAIvYDCSn7wr3RIg+PK2cu s0KbJeUP+j19Zet0PPIt74RLa9adWYMa1jLf8QqTaw== X-Google-Smtp-Source: ALg8bN4x0rWJJPfHRJLDWBcg/+VI1DAnL4fNA4zm/Xd1TabqK6FdGdT1O6S4f78aGwbCWEkS+z4dFToFbQumpXQP3w8= X-Received: by 2002:a5d:8410:: with SMTP id i16mr18634154ion.173.1548148926970; Tue, 22 Jan 2019 01:22:06 -0800 (PST) MIME-Version: 1.0 References: <20181221170021.145024-1-sami.mujawar@arm.com> <20181221170021.145024-6-sami.mujawar@arm.com> In-Reply-To: From: Ard Biesheuvel Date: Tue, 22 Jan 2019 10:21:55 +0100 Message-ID: To: Sami Mujawar Cc: "edk2-devel@lists.01.org" , Arvind Chauhan , Daniil Egranov , Thomas Abraham , Leif Lindholm , "Kinney, Michael D" , Alexei Fedorov , Matteo Carlini , Stephanie Hughes-Fitt , nd Subject: Re: [PATCH edk2-platforms v1 5/6] Platform/ARM: Add OEM CPU generator for FVP X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2019 09:22:08 -0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, 21 Dec 2018 at 19:14, Sami Mujawar wrote: > > Hi Ard, > > Please see my response inline. > > Regards, > > Sami Mujawar > > -----Original Message----- > From: Ard Biesheuvel > Sent: 21 December 2018 05:08 PM > To: Sami Mujawar > Cc: edk2-devel@lists.01.org; Arvind Chauhan ; Dan= iil Egranov ; Thomas Abraham ; Leif Lindholm ; Kinney, Michael D ; Alexei Fedorov ; Matteo Carlini = ; Stephanie Hughes-Fitt ; nd > Subject: Re: [PATCH edk2-platforms v1 5/6] Platform/ARM: Add OEM CPU gene= rator for FVP > > Hi Sami, > > On Fri, 21 Dec 2018 at 18:01, Sami Mujawar wrote: > > > > Add support for dynamic generation of ACPI CPU device information. > > This generator uses the compiled data from a template asl file and > > patches it at runtime to generate the CPU information based on the > > number of CPUs and their ACPI UID. This patched data is then installed > > as a SSDT table. > > > > Contributed-under: TianoCore Contribution Agreement 1.1 > > Signed-off-by: Sami Mujawar > > --- > > Platform/ARM/VExpressPkg/ConfigurationManager/AcpiOemCpuGeneratorLib/A= cpiOemCpuASLLib.inf | 27 ++ > > Platform/ARM/VExpressPkg/ConfigurationManager/AcpiOemCpuGeneratorLib/A= cpiOemCpuGeneratorLib.inf | 42 ++ > > Platform/ARM/VExpressPkg/ConfigurationManager/AcpiOemCpuGeneratorLib/O= emCpuGenerator.c | 403 ++++++++++++++++++++ > > Platform/ARM/VExpressPkg/ConfigurationManager/AcpiOemCpuGeneratorLib/O= emCpuGenerator.h | 23 ++ > > Platform/ARM/VExpressPkg/ConfigurationManager/AcpiOemCpuGeneratorLib/S= sdtCpuTemplate.asl | 25 ++ > > 5 files changed, 520 insertions(+) > > > ... > > diff --git > > a/Platform/ARM/VExpressPkg/ConfigurationManager/AcpiOemCpuGeneratorLib > > /OemCpuGenerator.c > > b/Platform/ARM/VExpressPkg/ConfigurationManager/AcpiOemCpuGeneratorLib > > /OemCpuGenerator.c > > new file mode 100644 > > index > > 0000000000000000000000000000000000000000..d544244bfbd566c128b57d80b0c8 > > c2bdc0cca374 > > --- /dev/null > > +++ b/Platform/ARM/VExpressPkg/ConfigurationManager/AcpiOemCpuGenerato > > +++ rLib/OemCpuGenerator.c > > @@ -0,0 +1,403 @@ > > +/** @file > > + OEM CPU Table Generator > > + > > + Copyright (c) 2018, ARM 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. > > +**/ > > + > > +#include > > +#include > > +#include > > +#include > > +#include #include > > + > > +#include > > + > > +// Module specific include files. > > +#include > > +#include #include > > + #include > > +#include > > +#include > > + > > +#include > > + > > +// AML Code Include files generated by iASL Compiler #include > > + > > + > > +// AML Code offsets file generated by iASL Compiler #include > > + > > + > > Apologies if I should have spotted this before, but this is a no-go. > We are relying on intermediate output of some version of the IASL compile= r here, which [AFAIK] is not formally specified or documented. > We cannot base an elaborate framework like DynamicTables on this. > > I guess this only affects DSDT/SSDT generation, right? > [SAMI] Yes. The last 2 patches in this series add this feature. We probab= ly need more discussion on this topic. > Until then can we proceed with review of the remaining patches, or should= I submit a new patch series that drops the last 2 patches? > Could you look into whether EFI's ACPI SDT protocol has what you need to manipulate AML at runtime?