From nobody Thu Nov 14 17:15:15 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+45549+1787277+3901457@groups.io ARC-Seal: i=1; a=rsa-sha256; t=1565697489; cv=none; d=zoho.com; s=zohoarc; b=HXCk5TCi+npGYXbckhFN5seOHErnz55r16JWn2mEFSoCtkpJuP0abYWhv8WavFJCR9DSjElUO4BWXcdZmxjOnRAkuYt7rrWAzDNB38/Po3sQwlb/EInGw8Q7vB+RkYK1Vg7oOK1XApMzwicQtCaTs+gOitzNPYy4NSOUEolJj1Q= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1565697489; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Id:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To:ARC-Authentication-Results; bh=+nUzxnYVIhYze/wtKHErpsPikDZzgx4BQgRd5x9lDC4=; b=ojBOuWEUVgyO1PA+6KidDVA+YTgeda4HmV9gjqcM85UhA3GeakOYoAJK5unifTQUJKXYpH+xbOeEq2560BGqUsklblP81Yk204og02ewIdiQSEqq19gxFHbVQqZZV0XayyqfU9cweqvaE7G8wS73mL9raH3Hg9xWzBZR6oRaPHI= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+45549+1787277+3901457@groups.io Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 1565697489543165.8747231012003; Tue, 13 Aug 2019 04:58:09 -0700 (PDT) Return-Path: X-Received: from esa1.hc3370-68.iphmx.com (esa1.hc3370-68.iphmx.com [216.71.145.142]) by groups.io with SMTP; Tue, 13 Aug 2019 04:58:08 -0700 Received-SPF: pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+45549+1787277+3901457@groups.io; helo=web01.groups.io; Received-SPF: None (esa1.hc3370-68.iphmx.com: no sender authenticity information available from domain of anthony.perard@citrix.com) identity=pra; client-ip=162.221.158.21; receiver=esa1.hc3370-68.iphmx.com; envelope-from="anthony.perard@citrix.com"; x-sender="anthony.perard@citrix.com"; x-conformance=sidf_compatible Received-SPF: Pass (esa1.hc3370-68.iphmx.com: domain of anthony.perard@citrix.com designates 162.221.158.21 as permitted sender) identity=mailfrom; client-ip=162.221.158.21; receiver=esa1.hc3370-68.iphmx.com; envelope-from="anthony.perard@citrix.com"; x-sender="anthony.perard@citrix.com"; x-conformance=sidf_compatible; x-record-type="v=spf1"; x-record-text="v=spf1 ip4:209.167.231.154 ip4:178.63.86.133 ip4:195.66.111.40/30 ip4:85.115.9.32/28 ip4:199.102.83.4 ip4:192.28.146.160 ip4:192.28.146.107 ip4:216.52.6.88 ip4:216.52.6.188 ip4:162.221.158.21 ip4:162.221.156.83 ~all" Received-SPF: None (esa1.hc3370-68.iphmx.com: no sender authenticity information available from domain of postmaster@mail.citrix.com) identity=helo; client-ip=162.221.158.21; receiver=esa1.hc3370-68.iphmx.com; envelope-from="anthony.perard@citrix.com"; x-sender="postmaster@mail.citrix.com"; x-conformance=sidf_compatible IronPort-SDR: bFwtNUR30w8wOXgmCH2ZO5B0Kh3kNhmh+sPfcTND4Ygoi3Z9Ru/RFpe5MRB8iquQ1LsZ8r3nd/ bV7dpItBa8PQEKr6sPQxxz9SR/QbMfDv7UcQ2gu9o48U8MzImZk0GSo3UWQ39Zyvrgr5AtNL2c YfJ7T2/cXW/DBOL9ulgeiMGogfcslUGtLX1E6835F7+QiRIZMelP1u27yY2OGIyLDcea3xmng2 QNl82lJlS7e43brBZ9MEIRHjoYfX3MWKiGca0Ertwkbp3rsm46DSfw3atGdbyB/LlR3rbWq8iS 4VM= X-SBRS: 2.7 X-MesageID: 4242247 X-Ironport-Server: esa1.hc3370-68.iphmx.com X-Remote-IP: 162.221.158.21 X-Policy: $RELAYED X-IronPort-AV: E=Sophos;i="5.64,381,1559534400"; d="scan'208";a="4242247" From: "Anthony PERARD" To: CC: Laszlo Ersek , Jordan Justen , Julien Grall , , Ard Biesheuvel , Anthony PERARD Subject: [edk2-devel] [PATCH v5 14/35] OvmfPkg/AcpiPlatformDxe: Use XenPlatformLib Date: Tue, 13 Aug 2019 12:30:58 +0100 Message-ID: <20190813113119.14804-15-anthony.perard@citrix.com> In-Reply-To: <20190813113119.14804-1-anthony.perard@citrix.com> References: <20190813113119.14804-1-anthony.perard@citrix.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,anthony.perard@citrix.com Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1565697489; bh=+nUzxnYVIhYze/wtKHErpsPikDZzgx4BQgRd5x9lDC4=; h=CC:Content-Type:Date:From:Reply-To:Subject:To; b=mMAiL5INnSpVVChEoh9A0v3rmSQkVdA2HYvB/3eZQ20yIUJtOFGSi0CAuxnDWLTrwY4 WscHPhbEz/xn2Gehp6KhiMLxUCoCqF3wUEPwrRPgvqHs9rAjjYK+69s0JlnKlpL2qiZM5 WH1mDbHk01ySuVE2T2XgS/yyHu0SeVESokM= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Type: text/plain; charset="utf-8" This patch replace the XenDetected() function by the one in XenPlatformLib. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=3D1689 Signed-off-by: Anthony PERARD Reviewed-by: Laszlo Ersek --- Notes: v4: - removed gEfiXenInfoGuid from Guids list. =20 v3: - new patch, splited from the next patch (which was OvmfPkg/AcpiPlatformDxe: Use PVH RSDP if exist) OvmfPkg/OvmfPkgIa32.dsc | 1 + OvmfPkg/OvmfPkgIa32X64.dsc | 1 + OvmfPkg/OvmfPkgX64.dsc | 1 + OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf | 3 +-- OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h | 6 +----- OvmfPkg/AcpiPlatformDxe/Xen.c | 24 --------------------- 6 files changed, 5 insertions(+), 31 deletions(-) diff --git a/OvmfPkg/OvmfPkgIa32.dsc b/OvmfPkg/OvmfPkgIa32.dsc index 6ab7300186..66e944436a 100644 --- a/OvmfPkg/OvmfPkgIa32.dsc +++ b/OvmfPkg/OvmfPkgIa32.dsc @@ -200,6 +200,7 @@ [LibraryClasses] SmbusLib|MdePkg/Library/BaseSmbusLibNull/BaseSmbusLibNull.inf OrderedCollectionLib|MdePkg/Library/BaseOrderedCollectionRedBlackTreeLib= /BaseOrderedCollectionRedBlackTreeLib.inf XenHypercallLib|OvmfPkg/Library/XenHypercallLib/XenHypercallLib.inf + XenPlatformLib|OvmfPkg/Library/XenPlatformLib/XenPlatformLib.inf =20 !if $(TPM2_ENABLE) =3D=3D TRUE Tpm2CommandLib|SecurityPkg/Library/Tpm2CommandLib/Tpm2CommandLib.inf diff --git a/OvmfPkg/OvmfPkgIa32X64.dsc b/OvmfPkg/OvmfPkgIa32X64.dsc index f163aa2671..51c2bfb44f 100644 --- a/OvmfPkg/OvmfPkgIa32X64.dsc +++ b/OvmfPkg/OvmfPkgIa32X64.dsc @@ -205,6 +205,7 @@ [LibraryClasses] SmbusLib|MdePkg/Library/BaseSmbusLibNull/BaseSmbusLibNull.inf OrderedCollectionLib|MdePkg/Library/BaseOrderedCollectionRedBlackTreeLib= /BaseOrderedCollectionRedBlackTreeLib.inf XenHypercallLib|OvmfPkg/Library/XenHypercallLib/XenHypercallLib.inf + XenPlatformLib|OvmfPkg/Library/XenPlatformLib/XenPlatformLib.inf =20 !if $(TPM2_ENABLE) =3D=3D TRUE Tpm2CommandLib|SecurityPkg/Library/Tpm2CommandLib/Tpm2CommandLib.inf diff --git a/OvmfPkg/OvmfPkgX64.dsc b/OvmfPkg/OvmfPkgX64.dsc index fa98f16a3f..ba7a758844 100644 --- a/OvmfPkg/OvmfPkgX64.dsc +++ b/OvmfPkg/OvmfPkgX64.dsc @@ -205,6 +205,7 @@ [LibraryClasses] SmbusLib|MdePkg/Library/BaseSmbusLibNull/BaseSmbusLibNull.inf OrderedCollectionLib|MdePkg/Library/BaseOrderedCollectionRedBlackTreeLib= /BaseOrderedCollectionRedBlackTreeLib.inf XenHypercallLib|OvmfPkg/Library/XenHypercallLib/XenHypercallLib.inf + XenPlatformLib|OvmfPkg/Library/XenPlatformLib/XenPlatformLib.inf =20 !if $(TPM2_ENABLE) =3D=3D TRUE Tpm2CommandLib|SecurityPkg/Library/Tpm2CommandLib/Tpm2CommandLib.inf diff --git a/OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf b/OvmfPkg/AcpiPlat= formDxe/AcpiPlatformDxe.inf index 24634eeae2..e486b8afa5 100644 --- a/OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf +++ b/OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf @@ -44,13 +44,13 @@ [LibraryClasses] DebugLib UefiBootServicesTableLib UefiDriverEntryPoint - HobLib QemuFwCfgLib QemuFwCfgS3Lib MemoryAllocationLib BaseLib DxeServicesTableLib OrderedCollectionLib + XenPlatformLib =20 [Protocols] gEfiAcpiTableProtocolGuid # PROTOCOL ALWAYS_CONSUMED @@ -58,7 +58,6 @@ [Protocols] gEfiPciIoProtocolGuid # PROTOCOL SOMETIMES_CONSU= MED =20 [Guids] - gEfiXenInfoGuid gRootBridgesConnectedEventGroupGuid =20 [Pcd] diff --git a/OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h b/OvmfPkg/AcpiPlatformD= xe/AcpiPlatform.h index 3037afcf18..9597e028e4 100644 --- a/OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h +++ b/OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h @@ -19,6 +19,7 @@ #include #include #include +#include =20 #include =20 @@ -52,11 +53,6 @@ QemuInstallAcpiTable ( OUT UINTN *TableKey ); =20 -BOOLEAN -XenDetected ( - VOID - ); - EFI_STATUS EFIAPI InstallXenTables ( diff --git a/OvmfPkg/AcpiPlatformDxe/Xen.c b/OvmfPkg/AcpiPlatformDxe/Xen.c index e4e47bf0e8..82794b933e 100644 --- a/OvmfPkg/AcpiPlatformDxe/Xen.c +++ b/OvmfPkg/AcpiPlatformDxe/Xen.c @@ -9,8 +9,6 @@ **/=20 =20 #include "AcpiPlatform.h" -#include -#include #include =20 #define XEN_ACPI_PHYSICAL_ADDRESS 0x000EA020 @@ -18,28 +16,6 @@ =20 EFI_ACPI_2_0_ROOT_SYSTEM_DESCRIPTION_POINTER *XenAcpiRsdpStructurePtr =3D= NULL; =20 -/** - This function detects if OVMF is running on Xen. - -**/ -BOOLEAN -XenDetected ( - VOID - ) -{ - EFI_HOB_GUID_TYPE *GuidHob; - - // - // See if a XenInfo HOB is available - // - GuidHob =3D GetFirstGuidHob (&gEfiXenInfoGuid); - if (GuidHob =3D=3D NULL) { - return FALSE; - } - - return TRUE; -} - /** Get the address of Xen ACPI Root System Description Pointer (RSDP) structure. --=20 Anthony PERARD -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#45549): https://edk2.groups.io/g/devel/message/45549 Mute This Topic: https://groups.io/mt/32851697/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-