From ec42c8dc69be8eda4fc794c8cd5f030ed38cea30 Mon Sep 17 00:00:00 2001 From: Stefan Berger Date: Sat, 21 Nov 2015 14:54:41 -0500 Subject: tpm: Set timeouts and durations to microsecond values Fix the timeouts and durations -- they are provided in microseconds. Adapt the TPM driver for it. Get TPM specific timeout and duration values earlier from the device. Signed-off-by: Stefan Berger --- src/tcgbios.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/tcgbios.c') diff --git a/src/tcgbios.c b/src/tcgbios.c index decf0fd4..38bc7376 100644 --- a/src/tcgbios.c +++ b/src/tcgbios.c @@ -459,6 +459,10 @@ tpm_startup(void) if (rc || returnCode) goto err_exit; + rc = determine_timeouts(); + if (rc) + goto err_exit; + rc = build_and_send_cmd(0, TPM_ORD_SelfTestFull, NULL, 0, NULL, 0, &returnCode, TPM_DURATION_TYPE_LONG); @@ -477,10 +481,6 @@ tpm_startup(void) if (rc || (returnCode != 0 && returnCode != TPM_BAD_LOCALITY)) goto err_exit; - rc = determine_timeouts(); - if (rc) - goto err_exit; - rc = tpm_smbios_measure(); if (rc) goto err_exit; -- cgit