diff options
author | Philipp Deppenwiese <zaolin@das-labor.org> | 2017-05-03 03:48:51 +0200 |
---|---|---|
committer | Martin Roth <martinroth@google.com> | 2017-05-05 23:33:08 +0200 |
commit | 35418f9814a64073550eb63a3bcb2e79021347cb (patch) | |
tree | b2f0e6c064823e2abaf135687e3325e66ac745a4 /src/drivers/pc80 | |
parent | 4aaa7e35f5eaa0a97f0564406e8e2ad1398fa740 (diff) |
drivers/pc80/tpm: Fix missing tis_close() function
tis_close() must be called after tis_open() otherwise the locked
locality isn't released and the sessions hangs.
Tested=PC Engines APU2
Change-Id: I1a06f6a29015708e4bc1de6e6678827c28b84e98
Signed-off-by: Philipp Deppenwiese <zaolin@das-labor.org>
Reviewed-on: https://review.coreboot.org/19535
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Diffstat (limited to 'src/drivers/pc80')
-rw-r--r-- | src/drivers/pc80/tpm/romstage.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/drivers/pc80/tpm/romstage.c b/src/drivers/pc80/tpm/romstage.c index a257ba1610..5531458726 100644 --- a/src/drivers/pc80/tpm/romstage.c +++ b/src/drivers/pc80/tpm/romstage.c @@ -215,7 +215,6 @@ void init_tpm(int s3resume) if (tis_open()) return; - if (s3resume) { /* S3 Resume */ printk(BIOS_SPEW, "TPM: Resume\n"); @@ -226,6 +225,7 @@ void init_tpm(int s3resume) * in S3, so it's already initialized. */ printk(BIOS_DEBUG, "TPM: Already initialized.\n"); + tis_close(); return; } } else { @@ -234,6 +234,8 @@ void init_tpm(int s3resume) response, sizeof(response)); } + tis_close(); + if (result == TPM_SUCCESS) { printk(BIOS_SPEW, "TPM: OK.\n"); return; |