summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorJason Gunthorpe <jgunthorpe@obsidianresearch.com>2014-05-21 18:26:44 -0600
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-09-17 09:19:08 -0700
commit8b5a02ed633c1bfa97359abcd098aac689c1ca9b (patch)
treef995f1102fb984b59fa751a819affcd19dcc6880 /include/linux
parent9124fa935352e7041fbd5e2ba9574aa32b61e97c (diff)
downloadlinux-stable-8b5a02ed633c1bfa97359abcd098aac689c1ca9b.tar.gz
linux-stable-8b5a02ed633c1bfa97359abcd098aac689c1ca9b.tar.bz2
linux-stable-8b5a02ed633c1bfa97359abcd098aac689c1ca9b.zip
tpm: Provide a generic means to override the chip returned timeouts
commit 8e54caf407b98efa05409e1fee0e5381abd2b088 upstream. Some Atmel TPMs provide completely wrong timeouts from their TPM_CAP_PROP_TIS_TIMEOUT query. This patch detects that and returns new correct values via a DID/VID table in the TIS driver. Tested on ARM using an AT97SC3204T FW version 37.16 [PHuewe: without this fix these 'broken' Atmel TPMs won't function on older kernels] Signed-off-by: "Berg, Christopher" <Christopher.Berg@atmel.com> Signed-off-by: Jason Gunthorpe <jgunthorpe@obsidianresearch.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/tpm.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/tpm.h b/include/linux/tpm.h
index fff1d0976f80..8350c538b486 100644
--- a/include/linux/tpm.h
+++ b/include/linux/tpm.h
@@ -39,6 +39,9 @@ struct tpm_class_ops {
int (*send) (struct tpm_chip *chip, u8 *buf, size_t len);
void (*cancel) (struct tpm_chip *chip);
u8 (*status) (struct tpm_chip *chip);
+ bool (*update_timeouts)(struct tpm_chip *chip,
+ unsigned long *timeout_cap);
+
};
#if defined(CONFIG_TCG_TPM) || defined(CONFIG_TCG_TPM_MODULE)