diff options
author | Ard Biesheuvel <ardb@kernel.org> | 2019-12-24 18:10:11 +0300 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2019-12-25 12:49:18 +0300 |
commit | 960a8d01834eabc4549928c60f8ce0300ad08519 (patch) | |
tree | 5b8c71ad5a440efa45c4ea145aab52fe7ecf3330 /drivers/firmware/efi/libstub/tpm.c | |
parent | e8bd5ddf60eedd6d584fa1e98d0cfe45abe95043 (diff) | |
download | linux-960a8d01834eabc4549928c60f8ce0300ad08519.tar.xz |
efi/libstub: Use stricter typing for firmware function pointers
We will soon remove another level of pointer casting, so let's make
sure all type handling involving firmware calls at boot time is correct.
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Cc: Arvind Sankar <nivedita@alum.mit.edu>
Cc: Borislav Petkov <bp@alien8.de>
Cc: James Morse <james.morse@arm.com>
Cc: Matt Fleming <matt@codeblueprint.co.uk>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-efi@vger.kernel.org
Link: https://lkml.kernel.org/r/20191224151025.32482-12-ardb@kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'drivers/firmware/efi/libstub/tpm.c')
-rw-r--r-- | drivers/firmware/efi/libstub/tpm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/firmware/efi/libstub/tpm.c b/drivers/firmware/efi/libstub/tpm.c index eb9af83e4d59..d270acd43de8 100644 --- a/drivers/firmware/efi/libstub/tpm.c +++ b/drivers/firmware/efi/libstub/tpm.c @@ -69,11 +69,11 @@ void efi_retrieve_tpm2_eventlog(efi_system_table_t *sys_table_arg) size_t log_size, last_entry_size; efi_bool_t truncated; int version = EFI_TCG2_EVENT_LOG_FORMAT_TCG_2; - void *tcg2_protocol = NULL; + efi_tcg2_protocol_t *tcg2_protocol = NULL; int final_events_size = 0; status = efi_call_early(locate_protocol, &tcg2_guid, NULL, - &tcg2_protocol); + (void **)&tcg2_protocol); if (status != EFI_SUCCESS) return; |