summaryrefslogtreecommitdiffstats
path: root/drivers/char/tpm/tpm_tis.c
diff options
context:
space:
mode:
authorRajiv Andrade <srajiv@linux.vnet.ibm.com>2011-11-01 20:00:52 +0100
committerRajiv Andrade <srajiv@linux.vnet.ibm.com>2011-11-16 12:57:11 +0100
commitb9e3238aa36db33aa0d0bd44ef85297c45627aac (patch)
tree5c9d90539b5730df66d8dfa26f025b2be898a006 /drivers/char/tpm/tpm_tis.c
parentTPM: NSC and TIS drivers X86 dependency fix (diff)
downloadlinux-b9e3238aa36db33aa0d0bd44ef85297c45627aac.tar.xz
linux-b9e3238aa36db33aa0d0bd44ef85297c45627aac.zip
TPM: fix transmit_cmd error logic
It's incorrect to assume that buffers returned by the TPM 10 bytes long are always error reports. This patches parses the error field in its header instead. The error report is now being printed using dev_err() instead of dev_dbg(), making it easier for users to provide more detailed bug reports. Signed-off-by: Rajiv Andrade <srajiv@linux.vnet.ibm.com>
Diffstat (limited to 'drivers/char/tpm/tpm_tis.c')
-rw-r--r--drivers/char/tpm/tpm_tis.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/char/tpm/tpm_tis.c b/drivers/char/tpm/tpm_tis.c
index 92f9f34e88f7..10cc44ceb5d1 100644
--- a/drivers/char/tpm/tpm_tis.c
+++ b/drivers/char/tpm/tpm_tis.c
@@ -29,8 +29,6 @@
#include <linux/freezer.h>
#include "tpm.h"
-#define TPM_HEADER_SIZE 10
-
enum tis_access {
TPM_ACCESS_VALID = 0x80,
TPM_ACCESS_ACTIVE_LOCALITY = 0x20,