diff options
author | Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> | 2014-12-12 14:46:37 -0500 |
---|---|---|
committer | Peter Huewe <peterhuewe@gmx.de> | 2015-01-17 08:00:10 -0500 |
commit | 313d21eeab9282e01fdcecd40e9ca87e0953627f (patch) | |
tree | c33c8a7d1bc2c589a7673e3781c4d3538059c896 /Documentation | |
parent | 71ed848fd791bc0b53a1b7a04f29eb9e994c7cbb (diff) |
tpm: device class for tpm
Added own device class for TPM. Uses MISC_MAJOR:TPM_MINOR for the
first character device in order to retain backwards compatibility.
Added tpm_dev_release() back attached to the character device.
I've been running this code now for a while on my laptop (Lenovo
T430S) TrouSerS works perfectly without modifications. I don't
believe it breaks anything significantly.
The sysfs attributes that have been placed under the wrong place
and are against sysfs-rules.txt should be probably left to
stagnate under platform device directory and start defining
new sysfs attributes to the char device directory.
Guidelines for future TPM sysfs attributes should be probably
along the lines of
- Single flat set of mandatory sysfs attributes. For example,
current PPI interface is way way too rich when you only want
to use it to clear and activate the TPM.
- Define sysfs attribute if and only if there's no way to get
the value from ring-3. No attributes for TPM properties. It's
just unnecessary maintenance hurdle that we don't want.
Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Reviewed-by: Jasob Gunthorpe <jason.gunthorpe@obsidianresearch.com>
Reviewed-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Tested-by: Scot Doyle <lkml14@scotdoyle.com>
Tested-by: Peter Huewe <peterhuewe@gmx.de>
Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/ABI/stable/sysfs-class-tpm | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/Documentation/ABI/stable/sysfs-class-tpm b/Documentation/ABI/stable/sysfs-class-tpm index a60b45e2493b..9f790eebb5d2 100644 --- a/Documentation/ABI/stable/sysfs-class-tpm +++ b/Documentation/ABI/stable/sysfs-class-tpm | |||
@@ -1,4 +1,4 @@ | |||
1 | What: /sys/class/misc/tpmX/device/ | 1 | What: /sys/class/tpm/tpmX/device/ |
2 | Date: April 2005 | 2 | Date: April 2005 |
3 | KernelVersion: 2.6.12 | 3 | KernelVersion: 2.6.12 |
4 | Contact: tpmdd-devel@lists.sf.net | 4 | Contact: tpmdd-devel@lists.sf.net |
@@ -6,7 +6,7 @@ Description: The device/ directory under a specific TPM instance exposes | |||
6 | the properties of that TPM chip | 6 | the properties of that TPM chip |
7 | 7 | ||
8 | 8 | ||
9 | What: /sys/class/misc/tpmX/device/active | 9 | What: /sys/class/tpm/tpmX/device/active |
10 | Date: April 2006 | 10 | Date: April 2006 |
11 | KernelVersion: 2.6.17 | 11 | KernelVersion: 2.6.17 |
12 | Contact: tpmdd-devel@lists.sf.net | 12 | Contact: tpmdd-devel@lists.sf.net |
@@ -18,7 +18,7 @@ Description: The "active" property prints a '1' if the TPM chip is accepting | |||
18 | section 17 for more information on which commands are | 18 | section 17 for more information on which commands are |
19 | available. | 19 | available. |
20 | 20 | ||
21 | What: /sys/class/misc/tpmX/device/cancel | 21 | What: /sys/class/tpm/tpmX/device/cancel |
22 | Date: June 2005 | 22 | Date: June 2005 |
23 | KernelVersion: 2.6.13 | 23 | KernelVersion: 2.6.13 |
24 | Contact: tpmdd-devel@lists.sf.net | 24 | Contact: tpmdd-devel@lists.sf.net |
@@ -26,7 +26,7 @@ Description: The "cancel" property allows you to cancel the currently | |||
26 | pending TPM command. Writing any value to cancel will call the | 26 | pending TPM command. Writing any value to cancel will call the |
27 | TPM vendor specific cancel operation. | 27 | TPM vendor specific cancel operation. |
28 | 28 | ||
29 | What: /sys/class/misc/tpmX/device/caps | 29 | What: /sys/class/tpm/tpmX/device/caps |
30 | Date: April 2005 | 30 | Date: April 2005 |
31 | KernelVersion: 2.6.12 | 31 | KernelVersion: 2.6.12 |
32 | Contact: tpmdd-devel@lists.sf.net | 32 | Contact: tpmdd-devel@lists.sf.net |
@@ -43,7 +43,7 @@ Description: The "caps" property contains TPM manufacturer and version info. | |||
43 | the chip supports. Firmware version is that of the chip and | 43 | the chip supports. Firmware version is that of the chip and |
44 | is manufacturer specific. | 44 | is manufacturer specific. |
45 | 45 | ||
46 | What: /sys/class/misc/tpmX/device/durations | 46 | What: /sys/class/tpm/tpmX/device/durations |
47 | Date: March 2011 | 47 | Date: March 2011 |
48 | KernelVersion: 3.1 | 48 | KernelVersion: 3.1 |
49 | Contact: tpmdd-devel@lists.sf.net | 49 | Contact: tpmdd-devel@lists.sf.net |
@@ -66,7 +66,7 @@ Description: The "durations" property shows the 3 vendor-specific values | |||
66 | scaled to be displayed in usecs. In this case "[adjusted]" | 66 | scaled to be displayed in usecs. In this case "[adjusted]" |
67 | will be displayed in place of "[original]". | 67 | will be displayed in place of "[original]". |
68 | 68 | ||
69 | What: /sys/class/misc/tpmX/device/enabled | 69 | What: /sys/class/tpm/tpmX/device/enabled |
70 | Date: April 2006 | 70 | Date: April 2006 |
71 | KernelVersion: 2.6.17 | 71 | KernelVersion: 2.6.17 |
72 | Contact: tpmdd-devel@lists.sf.net | 72 | Contact: tpmdd-devel@lists.sf.net |
@@ -75,7 +75,7 @@ Description: The "enabled" property prints a '1' if the TPM chip is enabled, | |||
75 | may be visible but produce a '0' after some operation that | 75 | may be visible but produce a '0' after some operation that |
76 | disables the TPM. | 76 | disables the TPM. |
77 | 77 | ||
78 | What: /sys/class/misc/tpmX/device/owned | 78 | What: /sys/class/tpm/tpmX/device/owned |
79 | Date: April 2006 | 79 | Date: April 2006 |
80 | KernelVersion: 2.6.17 | 80 | KernelVersion: 2.6.17 |
81 | Contact: tpmdd-devel@lists.sf.net | 81 | Contact: tpmdd-devel@lists.sf.net |
@@ -83,7 +83,7 @@ Description: The "owned" property produces a '1' if the TPM_TakeOwnership | |||
83 | ordinal has been executed successfully in the chip. A '0' | 83 | ordinal has been executed successfully in the chip. A '0' |
84 | indicates that ownership hasn't been taken. | 84 | indicates that ownership hasn't been taken. |
85 | 85 | ||
86 | What: /sys/class/misc/tpmX/device/pcrs | 86 | What: /sys/class/tpm/tpmX/device/pcrs |
87 | Date: April 2005 | 87 | Date: April 2005 |
88 | KernelVersion: 2.6.12 | 88 | KernelVersion: 2.6.12 |
89 | Contact: tpmdd-devel@lists.sf.net | 89 | Contact: tpmdd-devel@lists.sf.net |
@@ -106,7 +106,7 @@ Description: The "pcrs" property will dump the current value of all Platform | |||
106 | 1.2 chips, PCRs represent SHA-1 hashes, which are 20 bytes | 106 | 1.2 chips, PCRs represent SHA-1 hashes, which are 20 bytes |
107 | long. Use the "caps" property to determine TPM version. | 107 | long. Use the "caps" property to determine TPM version. |
108 | 108 | ||
109 | What: /sys/class/misc/tpmX/device/pubek | 109 | What: /sys/class/tpm/tpmX/device/pubek |
110 | Date: April 2005 | 110 | Date: April 2005 |
111 | KernelVersion: 2.6.12 | 111 | KernelVersion: 2.6.12 |
112 | Contact: tpmdd-devel@lists.sf.net | 112 | Contact: tpmdd-devel@lists.sf.net |
@@ -158,7 +158,7 @@ Description: The "pubek" property will return the TPM's public endorsement | |||
158 | Modulus Length: 256 (bytes) | 158 | Modulus Length: 256 (bytes) |
159 | Modulus: The 256 byte Endorsement Key modulus | 159 | Modulus: The 256 byte Endorsement Key modulus |
160 | 160 | ||
161 | What: /sys/class/misc/tpmX/device/temp_deactivated | 161 | What: /sys/class/tpm/tpmX/device/temp_deactivated |
162 | Date: April 2006 | 162 | Date: April 2006 |
163 | KernelVersion: 2.6.17 | 163 | KernelVersion: 2.6.17 |
164 | Contact: tpmdd-devel@lists.sf.net | 164 | Contact: tpmdd-devel@lists.sf.net |
@@ -167,7 +167,7 @@ Description: The "temp_deactivated" property returns a '1' if the chip has | |||
167 | cycle. Whether a warm boot (reboot) will clear a TPM chip | 167 | cycle. Whether a warm boot (reboot) will clear a TPM chip |
168 | from a temp_deactivated state is platform specific. | 168 | from a temp_deactivated state is platform specific. |
169 | 169 | ||
170 | What: /sys/class/misc/tpmX/device/timeouts | 170 | What: /sys/class/tpm/tpmX/device/timeouts |
171 | Date: March 2011 | 171 | Date: March 2011 |
172 | KernelVersion: 3.1 | 172 | KernelVersion: 3.1 |
173 | Contact: tpmdd-devel@lists.sf.net | 173 | Contact: tpmdd-devel@lists.sf.net |