From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx2.freebsd.org (mx2.freebsd.org [96.47.72.81]) by mx.groups.io with SMTP id smtpd.web10.52578.1686549550915269553 for ; Sun, 11 Jun 2023 22:59:11 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@freebsd.org header.s=dkim header.b=dYt3Q7SV; spf=pass (domain: freebsd.org, ip: 96.47.72.81, mailfrom: corvink@freebsd.org) Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits)) (Client CN "mx1.freebsd.org", Issuer "R3" (verified OK)) by mx2.freebsd.org (Postfix) with ESMTPS id 4Qfgx94Kwmz3K3c; Mon, 12 Jun 2023 05:59:09 +0000 (UTC) (envelope-from corvink@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Qfgx93JKlz43gv; Mon, 12 Jun 2023 05:59:09 +0000 (UTC) (envelope-from corvink@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1686549549; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=J57zUNrvx7iH5HugywxUfcG9WJblV/ZlhY2uqFtb+3A=; b=dYt3Q7SVYZPU/Dbblh64K8BfJP8Cz5bl9C4ZI1UexU1GX3cMrXQRLBEEhukLBeCIY2/9Tj Lxe2l0cyKQaZ1Qg9Oxpk5ZYc8uQu98I8W+ncqR2JPSlcu9bkg1S1CY+fsAPS/29372nOuz Fl5WSOqSQ1bQv6OHfdsiBLougAgeCAMN9Y0PH2FDSczOD2Rmxrko+1GjbYK959E1Cd7knL Ina/eY6vN3qUAChlqaO/7eucRXg9pywO0+neCCYLVMsAwzsPn4YGMxKxtEwLMUn/In0bxo 8gEM0f7KJlwR1VVYeHVy1kg+fr4zaYSPlcWn9V90sXJ+brHP4teKcbdM7AwdVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1686549549; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=J57zUNrvx7iH5HugywxUfcG9WJblV/ZlhY2uqFtb+3A=; b=HYy1I6x4wsBX03RDxpK0EoQo1vbInd8FusNytPqOKW5qmLfIOPUYzj23e5/J4Xxx39k0V1 01V2VJOlKIvhbkZ9+THI2DigUQzsYnAatVxr4jquWbh9ynOQWwvhZwMJMpLqYFbLl6ko4x NtHokd7feSzmCJe3M4ILMe2k84nvdJM1T4Pe0HZLEheQ47U/HDK7vYKKcVTdOJbvL8+npY jSX/fp+Z3B4EChepglNDUazBscp8C06RfY72f4X/onz1YldKzPOlcimD8w1e/jMS8aHrSP gX00Zd10nZBvj/TomeBmjFVZckxagwU+hkih6xQiiLnFfYYjtSZ+2UhSifVZSw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1686549549; a=rsa-sha256; cv=none; b=F/l97H3nmlj33W/cJAIoa5+/Ohc2jpt6ImGctZ+6NvBQZf+RYkP9niuz3109HYZ73qHEYA cjPz6lPR4DPUSIlxSXhdJgIhHe3WpzeMXBmfr6D9F+Od67h+/ab1fvmzMGJO/7AW+EGVNV qr7OXgPSUQDLXXN+0Q0ehKgCu+GFdeEBDd24aHXotN+dTMcNkZIImy7KMSTH030uS6l/Jg 8xMrq6PPXgAaFya/bw3657YhWuT9bAVuJULZoKeKIvcQpj8gcw57dJDPmzCgAMX83eEYLe AKUcY144NIZaDp9oTgqYhL5xlsX+L79xekaoNYmVbz7AuJovH3Qvo/fFYr6PyQ== Received: from corvink-nb.beckhoff.com (unknown [195.226.174.194]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: corvink) by smtp.freebsd.org (Postfix) with ESMTPSA id 4Qfgx82BgdzG75; Mon, 12 Jun 2023 05:59:08 +0000 (UTC) (envelope-from corvink@FreeBSD.org) From: =?UTF-8?B?Q29ydmluIEvDtmhuZQ==?= To: devel@edk2.groups.io Cc: =?UTF-8?q?Corvin=20K=C3=B6hne?= , Rebecca Cran , Ard Biesheuvel , Jiewen Yao , Jordan Justen , Gerd Hoffmann , Peter Grehan Subject: [PATCH v3 1/1] OvmfPkg/Bhyve: include TPM driver Date: Mon, 12 Jun 2023 07:58:57 +0200 Message-Id: <20230612055857.35589-1-corvink@FreeBSD.org> X-Mailer: git-send-email 2.40.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Bhyve will gain support for TPM emulation in the near future. Therefore, prepare OVMF by copying all TPM driver used by qemu's OVMF DSC into the bhyve OVMF DSC. Signed-off-by: Corvin K=C3=B6hne Reviewed-by: Rebecca Cran Cc: Ard Biesheuvel Cc: Jiewen Yao Cc: Jordan Justen Cc: Gerd Hoffmann Cc: Peter Grehan --- OvmfPkg/Bhyve/BhyveX64.dsc | 17 +++++++++++++++-- OvmfPkg/Bhyve/BhyveX64.fdf | 7 +++++++ 2 files changed, 22 insertions(+), 2 deletions(-) diff --git a/OvmfPkg/Bhyve/BhyveX64.dsc b/OvmfPkg/Bhyve/BhyveX64.dsc index 7b974706f958..7fa40998ae80 100644 --- a/OvmfPkg/Bhyve/BhyveX64.dsc +++ b/OvmfPkg/Bhyve/BhyveX64.dsc @@ -32,6 +32,8 @@ [Defines] DEFINE SMM_REQUIRE =3D FALSE DEFINE SOURCE_DEBUG_ENABLE =3D FALSE =20 +!include OvmfPkg/Include/Dsc/OvmfTpmDefines.dsc.inc + # # Network definition # @@ -226,8 +228,7 @@ [LibraryClasses] OrderedCollectionLib|MdePkg/Library/BaseOrderedCollectionRedBlackTreeL= ib/BaseOrderedCollectionRedBlackTreeLib.inf XenPlatformLib|OvmfPkg/Library/XenPlatformLib/XenPlatformLib.inf =20 - Tcg2PhysicalPresenceLib|OvmfPkg/Library/Tcg2PhysicalPresenceLibNull/Dx= eTcg2PhysicalPresenceLib.inf - TpmMeasurementLib|MdeModulePkg/Library/TpmMeasurementLibNull/TpmMeasur= ementLibNull.inf +!include OvmfPkg/Include/Dsc/OvmfTpmLibs.dsc.inc =20 [LibraryClasses.common] BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf @@ -564,12 +565,17 @@ [PcdsDynamicDefault] =20 gEfiSecurityPkgTokenSpaceGuid.PcdOptionRomImageVerificationPolicy|0x00 =20 +!include OvmfPkg/Include/Dsc/OvmfTpmPcds.dsc.inc + # MdeModulePkg resolution sets up the system display resolution gEfiMdeModulePkgTokenSpaceGuid.PcdVideoHorizontalResolution|0 gEfiMdeModulePkgTokenSpaceGuid.PcdVideoVerticalResolution|0 gEfiMdeModulePkgTokenSpaceGuid.PcdConOutRow|0 gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn|0 =20 +[PcdsDynamicHii] +!include OvmfPkg/Include/Dsc/OvmfTpmPcdsHii.dsc.inc + ########################################################################= ######## # # Components Section - list of all EDK II Modules needed by this Platfor= m. @@ -609,6 +615,8 @@ [Components] } =20 +!include OvmfPkg/Include/Dsc/OvmfTpmComponentsPei.dsc.inc + # # DXE Phase modules # @@ -632,6 +640,7 @@ [Components] !if $(SECURE_BOOT_ENABLE) =3D=3D TRUE NULL|SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificat= ionLib.inf !endif +!include OvmfPkg/Include/Dsc/OvmfTpmSecurityStub.dsc.inc } =20 MdeModulePkg/Universal/EbcDxe/EbcDxe.inf @@ -826,3 +835,7 @@ [Components] NULL|MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLib.inf } =20 + # + # TPM support + # +!include OvmfPkg/Include/Dsc/OvmfTpmComponentsDxe.dsc.inc diff --git a/OvmfPkg/Bhyve/BhyveX64.fdf b/OvmfPkg/Bhyve/BhyveX64.fdf index 3f6270c048cc..c62d5757092e 100644 --- a/OvmfPkg/Bhyve/BhyveX64.fdf +++ b/OvmfPkg/Bhyve/BhyveX64.fdf @@ -158,6 +158,8 @@ [FV.PEIFV] INF OvmfPkg/Bhyve/SmmAccess/SmmAccessPei.inf !endif =20 +!include OvmfPkg/Include/Fdf/OvmfTpmPei.fdf.inc + ########################################################################= ######## =20 [FV.DXEFV] @@ -335,6 +337,11 @@ [FV.DXEFV] INF MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf !endif =20 +# +# TPM support +# +!include OvmfPkg/Include/Fdf/OvmfTpmDxe.fdf.inc + ########################################################################= ######## =20 [FV.FVMAIN_COMPACT] --=20 2.40.1