From c77c7f0a7d056cc94bf3a6e962e7a24036eb350b Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Mon, 27 Feb 2023 12:16:12 -0700 Subject: [PATCH] security/tpm/tspi: Fix preram TPM log max entries Pre-RAM TPM logs use a separate define for the max number of logs. This one fits into the 2 KiB region assigned to TPM_LOG in the CAR linker script. Change-Id: Idda08a33c4a29fcb50085ca93487585dedf11012 Signed-off-by: Jeremy Soller Signed-off-by: Tim Crawford Reviewed-on: https://review.coreboot.org/c/coreboot/+/73296 Tested-by: build bot (Jenkins) Reviewed-by: Matt DeVillier Reviewed-by: Arthur Heymans --- src/security/tpm/tspi/log.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/security/tpm/tspi/log.c b/src/security/tpm/tspi/log.c index 086acebe6a..b7e59f804e 100644 --- a/src/security/tpm/tspi/log.c +++ b/src/security/tpm/tspi/log.c @@ -98,7 +98,7 @@ void tpm_cb_preram_log_clear(void) { printk(BIOS_INFO, "TPM LOG: clearing preram log\n"); struct tpm_cb_log_table *tclt = (struct tpm_cb_log_table *)_tpm_log; - tclt->max_entries = MAX_TPM_LOG_ENTRIES; + tclt->max_entries = MAX_PRERAM_TPM_LOG_ENTRIES; tclt->num_entries = 0; }