From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by mx.groups.io with SMTP id smtpd.web11.800.1616610796802067132 for ; Wed, 24 Mar 2021 11:33:17 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=QleHxACU; spf=pass (domain: redhat.com, ip: 63.128.21.124, mailfrom: lersek@redhat.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1616610795; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=0roZjC4qrZqb2g38628bYgBiXvw7Mxab48JyOPjsx+g=; b=QleHxACUBbVoYFwtwQzuUrwfsbjdTgA3dqplQgHMKya8YoG9pBfp/EpIJqxqEUK2ShPm4x LHSWhctQ4RGgZQuE3KiE0BJQJfiygw+xSsW9F2B//X3igj5ifFNphSS+pyuShFAJ1rSCe7 LEKEpajYM2ZMYyQBDWGsmuXhSNDv0Us= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-458-riq_RKawOoGA1D041oFwEw-1; Wed, 24 Mar 2021 14:33:13 -0400 X-MC-Unique: riq_RKawOoGA1D041oFwEw-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 08BEE10066E0; Wed, 24 Mar 2021 18:33:13 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-115-138.ams2.redhat.com [10.36.115.138]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6991310013D7; Wed, 24 Mar 2021 18:33:12 +0000 (UTC) Subject: Re: [edk2-devel] [Patch V2 0/2] Let AcpiTableDxe driver install Acpi table from Hob To: Benjamin Doron , devel@edk2.groups.io References: <8ecc6ec1-f7a0-7878-ef57-b58f99bc3af2@redhat.com> <8402.1616604928827766426@groups.io> From: "Laszlo Ersek" Message-ID: <2e602df8-b1fc-193b-f61a-86802ace9108@redhat.com> Date: Wed, 24 Mar 2021 19:33:08 +0100 MIME-Version: 1.0 In-Reply-To: <8402.1616604928827766426@groups.io> X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=lersek@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit On 03/24/21 17:55, Benjamin Doron wrote: >> >> >>> Hi all, >>> Would it be acceptable/feasible for AcpiTableDxe or AcpiPlatformDxe (in >>> MdeModulePkg) to use `EfiGetSystemConfigurationTable` to get the RSDP >>> and then install the tables? It's a solution that uses the regular >>> UefiLib, so it avoids platform-specific quirks (and as I see it, if RSDP >>> is in the configuration table, we probably always want those tables). >> >> I'm sorry, I don't understand how this would help. > > As I understand it, the issue is that this patchset changes MdeModulePkg to do platform-specific parsing. > > Perhaps it would be an acceptable solution for platforms to retrieve the tables, then add > RSDP/them to the configuration table to be installed by AcpiTableDxe/AcpiPlatformDxe. > This allows MdeModulePkg to abstract away the parsing, only installing tables > available to it. But this is already the best approach, and already what's happening -- when you call EFI_ACPI_TABLE_PROTOCOL.InstallAcpiTable() from the platform's AcpiPlatformDxe, that's *how* you tell AcpiTableDxe in MdeModulePkg to pick up the table and hook it into the RSDT / XSDT / wherever, and also to manage RSD PTR as a UEFI configuration table. Are you (more or less) proposing a new EFI_ACPI_TABLE_PROTOCOL member function for taking a forest of ACPI tables, passed in by RSD PTR? Sorry about being dense. :) > (Currently, UefiPayloadPkg's BlSupportDxe retrieves the data from a HOB and calls > `gBS->InstallConfigurationTable` with the address of RSDP). > > I understand that this may not work for OVMF if tables are located differently in memory. > >> >> >>> Regarding UefiPayloadPkg: AcpiTableDxe is currently compiled (listed in >>> DSC) but not added to a FV (not listed in FDF). So, how has this been >>> tested? >> >> I assume through an out-of-tree platform. Many such core modules exist >> in edk2 that are not consumed by any of the virtual platforms in the >> edk2 repo itself (EmulatorPkg, ArmVirtPkg, OvmfPkg). > > This makes sense, but AcpiTableDxe must be added to UefiPayloadPkg's FDF > if patch 2/2 is merged. Otherwise, ACPI tables will not be advertised. > Good point; I missed that. (I'm not familiar with the UefiPayloadPkg FDF at all.) Laszlo