mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-08 19:09:57 +00:00
tpm_tis: add delay after aborting command
commit a927b81317 upstream.
This patch adds a delay after aborting a command. Some TPMs need
this and will not process the subsequent command correctly otherwise.
It's worth noting that a TPM randomly failing to process a command,
maps to randomly failing suspend/resume operations.
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Signed-off-by: Rajiv Andrade <srajiv@linux.vnet.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
64d4ed6a2f
commit
2c6b180537
@@ -432,6 +432,9 @@ static int probe_itpm(struct tpm_chip *chip)
|
|||||||
out:
|
out:
|
||||||
itpm = rem_itpm;
|
itpm = rem_itpm;
|
||||||
tpm_tis_ready(chip);
|
tpm_tis_ready(chip);
|
||||||
|
/* some TPMs need a break here otherwise they will not work
|
||||||
|
* correctly on the immediately subsequent command */
|
||||||
|
msleep(chip->vendor.timeout_b);
|
||||||
release_locality(chip, chip->vendor.locality, 0);
|
release_locality(chip, chip->vendor.locality, 0);
|
||||||
|
|
||||||
return rc;
|
return rc;
|
||||||
|
|||||||
Reference in New Issue
Block a user