From 2d82a3899bc0dcc4de65035d7b3b214b14b8ed6a Mon Sep 17 00:00:00 2001 From: Peter Jones Date: Tue, 1 Aug 2017 17:02:29 -0400 Subject: Make tpm.c build right on 32-bit platforms. EFI_PHYSICAL_ADDRESS is UINT64 everywhere, so you can't just copy a 32-bit pointer to it. Signed-off-by: Peter Jones --- tpm.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'tpm.c') diff --git a/tpm.c b/tpm.c index af6b126d..9fac27b2 100644 --- a/tpm.c +++ b/tpm.c @@ -1,6 +1,7 @@ #include #include #include +#include #include "tpm.h" @@ -331,8 +332,8 @@ EFI_STATUS tpm_measure_variable(CHAR16 *VarName, EFI_GUID VendorGuid, UINTN VarS CopyMem ((CHAR16 *)VarLog->UnicodeName + VarNameLength, VarData, VarSize); - Status = tpm_log_event_raw((EFI_PHYSICAL_ADDRESS)VarLog, VarLogSize, 7, - (CHAR8 *)VarLog, VarLogSize, + Status = tpm_log_event_raw((EFI_PHYSICAL_ADDRESS)(intptr_t)VarLog, + VarLogSize, 7, (CHAR8 *)VarLog, VarLogSize, EV_EFI_VARIABLE_AUTHORITY, NULL); FreePool(VarLog); -- cgit v1.2.3