Messages in this thread Patch in this message | | | Date | Wed, 01 Feb 2012 12:59:46 -0800 | From | Greg KH <> | Subject | [22/89] tpm_tis: add delay after aborting command |
| |
3.2-stable review patch. If anyone has any objections, please let me know.
------------------
From: Stefan Berger <stefanb@linux.vnet.ibm.com>
commit a927b8131794ee449b7f6666e7ab61301949b20f 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>
--- drivers/char/tpm/tpm_tis.c | 3 +++ 1 file changed, 3 insertions(+)
--- a/drivers/char/tpm/tpm_tis.c +++ b/drivers/char/tpm/tpm_tis.c @@ -432,6 +432,9 @@ static int probe_itpm(struct tpm_chip *c out: itpm = rem_itpm; 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); return rc;
| |