mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
tpm: Reserve the TPM final events table
UEFI systems provide a boot services protocol for obtaining the TPM event log, but this is unusable after ExitBootServices() is called. Unfortunately ExitBootServices() itself triggers additional TPM events that then can't be obtained using this protocol. The platform provides a mechanism for the OS to obtain these events by recording them to a separate UEFI configuration table which the OS can then map. Unfortunately this table isn't self describing in terms of providing its length, so we need to parse the events inside it to figure out how long it is. Since the table isn't mapped at this point, we need to extend the length calculation function to be able to map the event as it goes along. (Fixes by Bartosz Szczepanek <[email protected]>) Signed-off-by: Matthew Garrett <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Reviewed-by: Bartosz Szczepanek <[email protected]> Tested-by: Bartosz Szczepanek <[email protected]> Reviewed-by: Jarkko Sakkinen <[email protected]> Tested-by: Jarkko Sakkinen <[email protected]> Signed-off-by: Jarkko Sakkinen <[email protected]>
This commit is contained in:
parent
44038bc514
commit
c46f340569
5 changed files with 164 additions and 14 deletions
|
|
@ -36,7 +36,7 @@
|
|||
static size_t calc_tpm2_event_size(struct tcg_pcr_event2_head *event,
|
||||
struct tcg_pcr_event *event_header)
|
||||
{
|
||||
return __calc_tpm2_event_size(event, event_header);
|
||||
return __calc_tpm2_event_size(event, event_header, false);
|
||||
}
|
||||
|
||||
static void *tpm2_bios_measurements_start(struct seq_file *m, loff_t *pos)
|
||||
|
|
|
|||
Loading…
Reference in a new issue