aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMimi Zohar <zohar@linux.vnet.ibm.com>2013-05-21 10:40:47 -0400
committerKent Yoder <key@linux.vnet.ibm.com>2013-05-21 13:25:02 -0400
commit1c16c9636cad24f0e654f19e8f73ede0c7bd5540 (patch)
tree07500d4620798ffe17becf152f9f4fcca4c24451
parent4fba3c3ba5c6b7803f36db7d56a58fa3226458d9 (diff)
tpm: move TPM_DIGEST_SIZE defintion
IMA requires access to TPM_DIGEST_SIZE definition. This patch moves the definition to <linux/tpm.h>. Signed-off-by: Mimi Zohar <zohar@us.ibm.com> Signed-off-by: Kent Yoder <key@linux.vnet.ibm.com>
-rw-r--r--drivers/char/tpm/tpm.h1
-rw-r--r--include/linux/tpm.h2
2 files changed, 2 insertions, 1 deletions
diff --git a/drivers/char/tpm/tpm.h b/drivers/char/tpm/tpm.h
index 0770d1d79366..433423288709 100644
--- a/drivers/char/tpm/tpm.h
+++ b/drivers/char/tpm/tpm.h
@@ -272,7 +272,6 @@ typedef union {
272 struct tpm_output_header out; 272 struct tpm_output_header out;
273} tpm_cmd_header; 273} tpm_cmd_header;
274 274
275#define TPM_DIGEST_SIZE 20
276struct tpm_pcrread_out { 275struct tpm_pcrread_out {
277 u8 pcr_result[TPM_DIGEST_SIZE]; 276 u8 pcr_result[TPM_DIGEST_SIZE];
278} __packed; 277} __packed;
diff --git a/include/linux/tpm.h b/include/linux/tpm.h
index fcb627ff8d3e..9a9051bb1a03 100644
--- a/include/linux/tpm.h
+++ b/include/linux/tpm.h
@@ -22,6 +22,8 @@
22#ifndef __LINUX_TPM_H__ 22#ifndef __LINUX_TPM_H__
23#define __LINUX_TPM_H__ 23#define __LINUX_TPM_H__
24 24
25#define TPM_DIGEST_SIZE 20 /* Max TPM v1.2 PCR size */
26
25/* 27/*
26 * Chip num is this value or a valid tpm idx 28 * Chip num is this value or a valid tpm idx
27 */ 29 */