summaryrefslogtreecommitdiff
path: root/drivers/firmware
diff options
context:
space:
mode:
authorJerry Snitselaar <jsnitsel@redhat.com>2022-10-22 08:23:52 -0700
committerArd Biesheuvel <ardb@kernel.org>2022-10-24 08:04:25 +0200
commitf4cd18c5b2000df0c382f6530eeca9141ea41faf (patch)
tree2ea05695858db910ac565ccaf9440d0474d54384 /drivers/firmware
parent37926f96302d8b6c2bc97990d33e316a3ed6d67f (diff)
efi/tpm: Pass correct address to memblock_reserve
memblock_reserve() expects a physical address, but the address being passed for the TPM final events log is what was returned from early_memremap(). This results in something like the following: [ 0.000000] memblock_reserve: [0xffffffffff2c0000-0xffffffffff2c00e4] efi_tpm_eventlog_init+0x324/0x370 Pass the address from efi like what is done for the TPM events log. Fixes: c46f3405692d ("tpm: Reserve the TPM final events table") Cc: Matthew Garrett <mjg59@google.com> Cc: Jarkko Sakkinen <jarkko@kernel.org> Cc: Bartosz Szczepanek <bsz@semihalf.com> Cc: Ard Biesheuvel <ardb@kernel.org> Signed-off-by: Jerry Snitselaar <jsnitsel@redhat.com> Acked-by: Jarkko Sakkinen <jarkko@kernel.org> Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Diffstat (limited to 'drivers/firmware')
-rw-r--r--drivers/firmware/efi/tpm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/firmware/efi/tpm.c b/drivers/firmware/efi/tpm.c
index 8f665678e9e3..e8d69bd548f3 100644
--- a/drivers/firmware/efi/tpm.c
+++ b/drivers/firmware/efi/tpm.c
@@ -97,7 +97,7 @@ int __init efi_tpm_eventlog_init(void)
goto out_calc;
}
- memblock_reserve((unsigned long)final_tbl,
+ memblock_reserve(efi.tpm_final_log,
tbl_size + sizeof(*final_tbl));
efi_tpm_final_log_size = tbl_size;