diff options
author | Marc-André Lureau <marcandre.lureau@redhat.com> | 2020-02-26 16:24:30 +0100 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2020-03-04 12:22:07 +0000 |
commit | 89236992913fbd704e4c68f663d7c13528702a3c (patch) | |
tree | 2f7a0aae44f0c9dad1aaa4c26d61aa5f29de190e /OvmfPkg/OvmfPkgIa32X64.dsc | |
parent | 07952a962a40efe65729c3ccb9b8934571cec1af (diff) | |
download | edk2-89236992913fbd704e4c68f663d7c13528702a3c.tar.gz edk2-89236992913fbd704e4c68f663d7c13528702a3c.tar.bz2 edk2-89236992913fbd704e4c68f663d7c13528702a3c.zip |
OvmfPkg: detect TPM 1.2 in Tcg2ConfigPei
Complement commit 6cf1880fb5b ("OvmfPkg: add customized Tcg2ConfigPei
clone", 2018-03-09) by detecting TPM 1.2 devices.
Since Tpm12RequestUseTpm() returns success on any TPM interface,
(including FIFO & CRB which are TPM 2.0), try to send a GetTicks TPM
1.2 command to probe the version. In case of failure, fallback on TPM
2.0 path.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Stefan Berger <stefanb@linux.ibm.com>
Message-Id: <20200226152433.1295789-3-marcandre.lureau@redhat.com>
Tested-by: Simon Hardy <simon.hardy@itdev.co.uk>
Diffstat (limited to 'OvmfPkg/OvmfPkgIa32X64.dsc')
-rw-r--r-- | OvmfPkg/OvmfPkgIa32X64.dsc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/OvmfPkg/OvmfPkgIa32X64.dsc b/OvmfPkg/OvmfPkgIa32X64.dsc index cb8a15ee61..5a132de7e3 100644 --- a/OvmfPkg/OvmfPkgIa32X64.dsc +++ b/OvmfPkg/OvmfPkgIa32X64.dsc @@ -211,6 +211,7 @@ XenPlatformLib|OvmfPkg/Library/XenPlatformLib/XenPlatformLib.inf
!if $(TPM_ENABLE) == TRUE
+ Tpm12CommandLib|SecurityPkg/Library/Tpm12CommandLib/Tpm12CommandLib.inf
Tpm2CommandLib|SecurityPkg/Library/Tpm2CommandLib/Tpm2CommandLib.inf
Tcg2PhysicalPresenceLib|OvmfPkg/Library/Tcg2PhysicalPresenceLibQemu/DxeTcg2PhysicalPresenceLib.inf
Tcg2PpVendorLib|SecurityPkg/Library/Tcg2PpVendorLibNull/Tcg2PpVendorLibNull.inf
@@ -286,6 +287,7 @@ !if $(TPM_ENABLE) == TRUE
BaseCryptLib|CryptoPkg/Library/BaseCryptLib/PeiCryptLib.inf
+ Tpm12DeviceLib|SecurityPkg/Library/Tpm12DeviceLibDTpm/Tpm12DeviceLibDTpm.inf
Tpm2DeviceLib|SecurityPkg/Library/Tpm2DeviceLibDTpm/Tpm2DeviceLibDTpm.inf
!endif
|