UefiPayloadPkg: Parse coreboot's TPM PPI handoff buffer

Read the coreboot table containing the TPM PPI handoff buffer and
place it in gEfiTcgPhysicalPresenceInfoHob.

coreboot uses the same PPI interface as QEMU does and installs the
corresponding ACPI code to provide a full PPI interface to the OS.
The OS must reboot in order to execute the requests.

The corresponding coreboot patch can be found here:
https://review.coreboot.org/c/coreboot/+/45568

In a follow up commit the OvmfPkg PhysicalPresence library will be used
to confirm TPM PPI request. This is necessary as coreboot doesn't have
input drivers or a graphical UI that could be used.

Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
This commit is contained in:
Patrick Rudolph
2020-10-05 16:29:25 +02:00
committed by Tim Crawford
parent d296a36cc4
commit 7d5abcd016
9 changed files with 156 additions and 0 deletions

View File

@@ -0,0 +1,30 @@
/** @file
This file defines the hob structure for Tcg Physical Presence Interface.
Copyright (c) 2020, 9elements Agency GmbH<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
#ifndef __TCG_PHYSICAL_PRESENCE_GUID_H__
#define __TCG_PHYSICAL_PRESENCE_GUID_H__
///
/// TCG Physical Presence Information GUID
///
extern EFI_GUID gEfiTcgPhysicalPresenceInfoHobGuid;
typedef struct {
UINT32 PpiAddress;
UINT8 TpmVersion;
UINT8 PpiVersion;
} TCG_PHYSICAL_PRESENCE_INFO;
#define UEFIPAYLOAD_TPM_VERSION_UNSPEC 0
#define UEFIPAYLOAD_TPM_VERSION_1_2 1
#define UEFIPAYLOAD_TPM_VERSION_2 2
#define UEFIPAYLOAD_TPM_PPI_VERSION_NONE 0
#define UEFIPAYLOAD_TPM_PPI_VERSION_1_30 1
#endif