xref: /qemu/backends/tpm/tpm_ioctl.h (revision 312c5404011f6a80d1467a19abd916fd203dd7d4)
1f4ede81eSAmarnath Valluri /*
2f4ede81eSAmarnath Valluri  * tpm_ioctl.h
3f4ede81eSAmarnath Valluri  *
4f4ede81eSAmarnath Valluri  * (c) Copyright IBM Corporation 2014, 2015.
5f4ede81eSAmarnath Valluri  *
6f4ede81eSAmarnath Valluri  * This file is licensed under the terms of the 3-clause BSD license
7f4ede81eSAmarnath Valluri  */
8efef4756SStefan Berger #ifndef _TPM_IOCTL_H_
9efef4756SStefan Berger #define _TPM_IOCTL_H_
10a8b991b5SMarkus Armbruster 
11efef4756SStefan Berger #if defined(__CYGWIN__)
12efef4756SStefan Berger # define __USE_LINUX_IOCTL_DEFS
13efef4756SStefan Berger #endif
14f4ede81eSAmarnath Valluri 
15d1c637ecSBin Meng #ifndef _WIN32
16f4ede81eSAmarnath Valluri #include <sys/uio.h>
17f4ede81eSAmarnath Valluri #include <sys/ioctl.h>
18d1c637ecSBin Meng #endif
19f4ede81eSAmarnath Valluri 
20ded5d78cSThomas Huth #ifdef HAVE_SYS_IOCCOM_H
21ded5d78cSThomas Huth #include <sys/ioccom.h>
22ded5d78cSThomas Huth #endif
23ded5d78cSThomas Huth 
24f4ede81eSAmarnath Valluri /*
25f4ede81eSAmarnath Valluri  * Every response from a command involving a TPM command execution must hold
26f4ede81eSAmarnath Valluri  * the ptm_res as the first element.
27f4ede81eSAmarnath Valluri  * ptm_res corresponds to the error code of a command executed by the TPM.
28f4ede81eSAmarnath Valluri  */
29f4ede81eSAmarnath Valluri 
30f4ede81eSAmarnath Valluri typedef uint32_t ptm_res;
31f4ede81eSAmarnath Valluri 
32*312c5404SStefan Berger /* PTM_GET_CAPABILITY: Get supported capabilities (ioctl's) */
33*312c5404SStefan Berger struct ptm_cap_n {
34*312c5404SStefan Berger     union {
35*312c5404SStefan Berger         struct {
36*312c5404SStefan Berger             ptm_res tpm_result; /* will always be TPM_SUCCESS (0) */
37*312c5404SStefan Berger             uint32_t caps;
38*312c5404SStefan Berger         } resp; /* response */
39*312c5404SStefan Berger     } u;
40*312c5404SStefan Berger };
41*312c5404SStefan Berger 
42f4ede81eSAmarnath Valluri /* PTM_GET_TPMESTABLISHED: get the establishment bit */
43f4ede81eSAmarnath Valluri struct ptm_est {
44f4ede81eSAmarnath Valluri     union {
45f4ede81eSAmarnath Valluri         struct {
46f4ede81eSAmarnath Valluri             ptm_res tpm_result;
47f4ede81eSAmarnath Valluri             unsigned char bit; /* TPM established bit */
48f4ede81eSAmarnath Valluri         } resp; /* response */
49f4ede81eSAmarnath Valluri     } u;
50f4ede81eSAmarnath Valluri };
51f4ede81eSAmarnath Valluri 
52f4ede81eSAmarnath Valluri /* PTM_RESET_TPMESTABLISHED: reset establishment bit */
53f4ede81eSAmarnath Valluri struct ptm_reset_est {
54f4ede81eSAmarnath Valluri     union {
55f4ede81eSAmarnath Valluri         struct {
56f4ede81eSAmarnath Valluri             uint8_t loc; /* locality to use */
57f4ede81eSAmarnath Valluri         } req; /* request */
58f4ede81eSAmarnath Valluri         struct {
59f4ede81eSAmarnath Valluri             ptm_res tpm_result;
60f4ede81eSAmarnath Valluri         } resp; /* response */
61f4ede81eSAmarnath Valluri     } u;
62f4ede81eSAmarnath Valluri };
63f4ede81eSAmarnath Valluri 
64f4ede81eSAmarnath Valluri /* PTM_INIT */
65f4ede81eSAmarnath Valluri struct ptm_init {
66f4ede81eSAmarnath Valluri     union {
67f4ede81eSAmarnath Valluri         struct {
68f4ede81eSAmarnath Valluri             uint32_t init_flags; /* see definitions below */
69f4ede81eSAmarnath Valluri         } req; /* request */
70f4ede81eSAmarnath Valluri         struct {
71f4ede81eSAmarnath Valluri             ptm_res tpm_result;
72f4ede81eSAmarnath Valluri         } resp; /* response */
73f4ede81eSAmarnath Valluri     } u;
74f4ede81eSAmarnath Valluri };
75f4ede81eSAmarnath Valluri 
76f4ede81eSAmarnath Valluri /* above init_flags */
77f4ede81eSAmarnath Valluri #define PTM_INIT_FLAG_DELETE_VOLATILE (1 << 0)
78f4ede81eSAmarnath Valluri     /* delete volatile state file after reading it */
79f4ede81eSAmarnath Valluri 
80f4ede81eSAmarnath Valluri /* PTM_SET_LOCALITY */
81f4ede81eSAmarnath Valluri struct ptm_loc {
82f4ede81eSAmarnath Valluri     union {
83f4ede81eSAmarnath Valluri         struct {
84f4ede81eSAmarnath Valluri             uint8_t loc; /* locality to set */
85f4ede81eSAmarnath Valluri         } req; /* request */
86f4ede81eSAmarnath Valluri         struct {
87f4ede81eSAmarnath Valluri             ptm_res tpm_result;
88f4ede81eSAmarnath Valluri         } resp; /* response */
89f4ede81eSAmarnath Valluri     } u;
90f4ede81eSAmarnath Valluri };
91f4ede81eSAmarnath Valluri 
92f4ede81eSAmarnath Valluri /* PTM_HASH_DATA: hash given data */
93f4ede81eSAmarnath Valluri struct ptm_hdata {
94f4ede81eSAmarnath Valluri     union {
95f4ede81eSAmarnath Valluri         struct {
96f4ede81eSAmarnath Valluri             uint32_t length;
97f4ede81eSAmarnath Valluri             uint8_t data[4096];
98f4ede81eSAmarnath Valluri         } req; /* request */
99f4ede81eSAmarnath Valluri         struct {
100f4ede81eSAmarnath Valluri             ptm_res tpm_result;
101f4ede81eSAmarnath Valluri         } resp; /* response */
102f4ede81eSAmarnath Valluri     } u;
103f4ede81eSAmarnath Valluri };
104f4ede81eSAmarnath Valluri 
105f4ede81eSAmarnath Valluri /*
106f4ede81eSAmarnath Valluri  * size of the TPM state blob to transfer; x86_64 can handle 8k,
107f4ede81eSAmarnath Valluri  * ppc64le only ~7k; keep the response below a 4k page size
108f4ede81eSAmarnath Valluri  */
109f4ede81eSAmarnath Valluri #define PTM_STATE_BLOB_SIZE (3 * 1024)
110f4ede81eSAmarnath Valluri 
111f4ede81eSAmarnath Valluri /*
112f4ede81eSAmarnath Valluri  * The following is the data structure to get state blobs from the TPM.
113f4ede81eSAmarnath Valluri  * If the size of the state blob exceeds the PTM_STATE_BLOB_SIZE, multiple reads
114f4ede81eSAmarnath Valluri  * with this ioctl and with adjusted offset are necessary. All bytes
115f4ede81eSAmarnath Valluri  * must be transferred and the transfer is done once the last byte has been
116f4ede81eSAmarnath Valluri  * returned.
117f4ede81eSAmarnath Valluri  * It is possible to use the read() interface for reading the data; however, the
118f4ede81eSAmarnath Valluri  * first bytes of the state blob will be part of the response to the ioctl(); a
119f4ede81eSAmarnath Valluri  * subsequent read() is only necessary if the total length (totlength) exceeds
120f4ede81eSAmarnath Valluri  * the number of received bytes. seek() is not supported.
121f4ede81eSAmarnath Valluri  */
122f4ede81eSAmarnath Valluri struct ptm_getstate {
123f4ede81eSAmarnath Valluri     union {
124f4ede81eSAmarnath Valluri         struct {
125f4ede81eSAmarnath Valluri             uint32_t state_flags; /* may be: PTM_STATE_FLAG_DECRYPTED */
126f4ede81eSAmarnath Valluri             uint32_t type;        /* which blob to pull */
127f4ede81eSAmarnath Valluri             uint32_t offset;      /* offset from where to read */
128f4ede81eSAmarnath Valluri         } req; /* request */
129f4ede81eSAmarnath Valluri         struct {
130f4ede81eSAmarnath Valluri             ptm_res tpm_result;
131f4ede81eSAmarnath Valluri             uint32_t state_flags; /* may be: PTM_STATE_FLAG_ENCRYPTED */
132f4ede81eSAmarnath Valluri             uint32_t totlength;   /* total length that will be transferred */
133f4ede81eSAmarnath Valluri             uint32_t length;      /* number of bytes in following buffer */
134f4ede81eSAmarnath Valluri             uint8_t  data[PTM_STATE_BLOB_SIZE];
135f4ede81eSAmarnath Valluri         } resp; /* response */
136f4ede81eSAmarnath Valluri     } u;
137f4ede81eSAmarnath Valluri };
138f4ede81eSAmarnath Valluri 
139f4ede81eSAmarnath Valluri /* TPM state blob types */
140f4ede81eSAmarnath Valluri #define PTM_BLOB_TYPE_PERMANENT  1
141f4ede81eSAmarnath Valluri #define PTM_BLOB_TYPE_VOLATILE   2
142f4ede81eSAmarnath Valluri #define PTM_BLOB_TYPE_SAVESTATE  3
143f4ede81eSAmarnath Valluri 
144f4ede81eSAmarnath Valluri /* state_flags above : */
145f4ede81eSAmarnath Valluri #define PTM_STATE_FLAG_DECRYPTED     1 /* on input:  get decrypted state */
146f4ede81eSAmarnath Valluri #define PTM_STATE_FLAG_ENCRYPTED     2 /* on output: state is encrypted */
147f4ede81eSAmarnath Valluri 
148f4ede81eSAmarnath Valluri /*
149f4ede81eSAmarnath Valluri  * The following is the data structure to set state blobs in the TPM.
150f4ede81eSAmarnath Valluri  * If the size of the state blob exceeds the PTM_STATE_BLOB_SIZE, multiple
151f4ede81eSAmarnath Valluri  * 'writes' using this ioctl are necessary. The last packet is indicated
152f4ede81eSAmarnath Valluri  * by the length being smaller than the PTM_STATE_BLOB_SIZE.
153f4ede81eSAmarnath Valluri  * The very first packet may have a length indicator of '0' enabling
154f4ede81eSAmarnath Valluri  * a write() with all the bytes from a buffer. If the write() interface
155f4ede81eSAmarnath Valluri  * is used, a final ioctl with a non-full buffer must be made to indicate
156f4ede81eSAmarnath Valluri  * that all data were transferred (a write with 0 bytes would not work).
157f4ede81eSAmarnath Valluri  */
158f4ede81eSAmarnath Valluri struct ptm_setstate {
159f4ede81eSAmarnath Valluri     union {
160f4ede81eSAmarnath Valluri         struct {
161f4ede81eSAmarnath Valluri             uint32_t state_flags; /* may be PTM_STATE_FLAG_ENCRYPTED */
162f4ede81eSAmarnath Valluri             uint32_t type;        /* which blob to set */
163f4ede81eSAmarnath Valluri             uint32_t length;      /* length of the data;
164f4ede81eSAmarnath Valluri                                      use 0 on the first packet to
165f4ede81eSAmarnath Valluri                                      transfer using write() */
166f4ede81eSAmarnath Valluri             uint8_t data[PTM_STATE_BLOB_SIZE];
167f4ede81eSAmarnath Valluri         } req; /* request */
168f4ede81eSAmarnath Valluri         struct {
169f4ede81eSAmarnath Valluri             ptm_res tpm_result;
170f4ede81eSAmarnath Valluri         } resp; /* response */
171f4ede81eSAmarnath Valluri     } u;
172f4ede81eSAmarnath Valluri };
173f4ede81eSAmarnath Valluri 
174f4ede81eSAmarnath Valluri /*
175f4ede81eSAmarnath Valluri  * PTM_GET_CONFIG: Data structure to get runtime configuration information
176f4ede81eSAmarnath Valluri  * such as which keys are applied.
177f4ede81eSAmarnath Valluri  */
178f4ede81eSAmarnath Valluri struct ptm_getconfig {
179f4ede81eSAmarnath Valluri     union {
180f4ede81eSAmarnath Valluri         struct {
181f4ede81eSAmarnath Valluri             ptm_res tpm_result;
182f4ede81eSAmarnath Valluri             uint32_t flags;
183f4ede81eSAmarnath Valluri         } resp; /* response */
184f4ede81eSAmarnath Valluri     } u;
185f4ede81eSAmarnath Valluri };
186f4ede81eSAmarnath Valluri 
187f4ede81eSAmarnath Valluri #define PTM_CONFIG_FLAG_FILE_KEY        0x1
188f4ede81eSAmarnath Valluri #define PTM_CONFIG_FLAG_MIGRATION_KEY   0x2
189f4ede81eSAmarnath Valluri 
1909375c44fSStefan Berger /*
1919375c44fSStefan Berger  * PTM_SET_BUFFERSIZE: Set the buffer size to be used by the TPM.
1929375c44fSStefan Berger  * A 0 on input queries for the current buffer size. Any other
1939375c44fSStefan Berger  * number will try to set the buffer size. The returned number is
1949375c44fSStefan Berger  * the buffer size that will be used, which can be larger than the
1959375c44fSStefan Berger  * requested one, if it was below the minimum, or smaller than the
1969375c44fSStefan Berger  * requested one, if it was above the maximum.
1979375c44fSStefan Berger  */
1989375c44fSStefan Berger struct ptm_setbuffersize {
1999375c44fSStefan Berger     union {
2009375c44fSStefan Berger         struct {
2019375c44fSStefan Berger             uint32_t buffersize; /* 0 to query for current buffer size */
2029375c44fSStefan Berger         } req; /* request */
2039375c44fSStefan Berger         struct {
2049375c44fSStefan Berger             ptm_res tpm_result;
2059375c44fSStefan Berger             uint32_t buffersize; /* buffer size in use */
2069375c44fSStefan Berger             uint32_t minsize; /* min. supported buffer size */
2079375c44fSStefan Berger             uint32_t maxsize; /* max. supported buffer size */
2089375c44fSStefan Berger         } resp; /* response */
2099375c44fSStefan Berger     } u;
2109375c44fSStefan Berger };
2119375c44fSStefan Berger 
212efef4756SStefan Berger #define PTM_GETINFO_SIZE (3 * 1024)
213efef4756SStefan Berger /*
214efef4756SStefan Berger  * PTM_GET_INFO: Get info about the TPM implementation (from libtpms)
215efef4756SStefan Berger  *
216efef4756SStefan Berger  * This request allows to indirectly call TPMLIB_GetInfo(flags) and
217efef4756SStefan Berger  * retrieve information from libtpms.
218efef4756SStefan Berger  * Only one transaction is currently necessary for returning results
219efef4756SStefan Berger  * to a client. Therefore, totlength and length will be the same if
220efef4756SStefan Berger  * offset is 0.
221efef4756SStefan Berger  */
222efef4756SStefan Berger struct ptm_getinfo {
223efef4756SStefan Berger     union {
224efef4756SStefan Berger         struct {
225efef4756SStefan Berger             uint64_t flags;
226efef4756SStefan Berger             uint32_t offset;      /* offset from where to read */
227efef4756SStefan Berger             uint32_t pad;         /* 32 bit arch */
228efef4756SStefan Berger         } req; /* request */
229efef4756SStefan Berger         struct {
230efef4756SStefan Berger             ptm_res tpm_result;
231efef4756SStefan Berger             uint32_t totlength;
232efef4756SStefan Berger             uint32_t length;
233efef4756SStefan Berger             char buffer[PTM_GETINFO_SIZE];
234efef4756SStefan Berger         } resp; /* response */
235efef4756SStefan Berger     } u;
236efef4756SStefan Berger };
237efef4756SStefan Berger 
238efef4756SStefan Berger #define SWTPM_INFO_TPMSPECIFICATION ((uint64_t)1 << 0)
239efef4756SStefan Berger #define SWTPM_INFO_TPMATTRIBUTES    ((uint64_t)1 << 1)
240efef4756SStefan Berger 
241efef4756SStefan Berger /*
242efef4756SStefan Berger  * PTM_LOCK_STORAGE: Lock the storage and retry n times
243efef4756SStefan Berger  */
244efef4756SStefan Berger struct ptm_lockstorage {
245efef4756SStefan Berger     union {
246efef4756SStefan Berger         struct {
247efef4756SStefan Berger             uint32_t retries; /* number of retries */
248efef4756SStefan Berger         } req; /* request */
249efef4756SStefan Berger         struct {
250efef4756SStefan Berger             ptm_res tpm_result;
2510a19d879SMichael Tokarev         } resp; /* response */
252efef4756SStefan Berger     } u;
253efef4756SStefan Berger };
254f4ede81eSAmarnath Valluri 
255*312c5404SStefan Berger typedef uint64_t ptm_cap; /* CUSE-only; use ptm_cap_n otherwise */
256*312c5404SStefan Berger typedef struct ptm_cap_n ptm_cap_n;
257f4ede81eSAmarnath Valluri typedef struct ptm_est ptm_est;
258f4ede81eSAmarnath Valluri typedef struct ptm_reset_est ptm_reset_est;
259f4ede81eSAmarnath Valluri typedef struct ptm_loc ptm_loc;
260f4ede81eSAmarnath Valluri typedef struct ptm_hdata ptm_hdata;
261f4ede81eSAmarnath Valluri typedef struct ptm_init ptm_init;
262f4ede81eSAmarnath Valluri typedef struct ptm_getstate ptm_getstate;
263f4ede81eSAmarnath Valluri typedef struct ptm_setstate ptm_setstate;
264f4ede81eSAmarnath Valluri typedef struct ptm_getconfig ptm_getconfig;
2659375c44fSStefan Berger typedef struct ptm_setbuffersize ptm_setbuffersize;
266efef4756SStefan Berger typedef struct ptm_getinfo ptm_getinfo;
267efef4756SStefan Berger typedef struct ptm_lockstorage ptm_lockstorage;
268f4ede81eSAmarnath Valluri 
269f4ede81eSAmarnath Valluri /* capability flags returned by PTM_GET_CAPABILITY */
270f4ede81eSAmarnath Valluri #define PTM_CAP_INIT               (1)
271f4ede81eSAmarnath Valluri #define PTM_CAP_SHUTDOWN           (1 << 1)
272f4ede81eSAmarnath Valluri #define PTM_CAP_GET_TPMESTABLISHED (1 << 2)
273f4ede81eSAmarnath Valluri #define PTM_CAP_SET_LOCALITY       (1 << 3)
274f4ede81eSAmarnath Valluri #define PTM_CAP_HASHING            (1 << 4)
275f4ede81eSAmarnath Valluri #define PTM_CAP_CANCEL_TPM_CMD     (1 << 5)
276f4ede81eSAmarnath Valluri #define PTM_CAP_STORE_VOLATILE     (1 << 6)
277f4ede81eSAmarnath Valluri #define PTM_CAP_RESET_TPMESTABLISHED (1 << 7)
278f4ede81eSAmarnath Valluri #define PTM_CAP_GET_STATEBLOB      (1 << 8)
279f4ede81eSAmarnath Valluri #define PTM_CAP_SET_STATEBLOB      (1 << 9)
280f4ede81eSAmarnath Valluri #define PTM_CAP_STOP               (1 << 10)
281f4ede81eSAmarnath Valluri #define PTM_CAP_GET_CONFIG         (1 << 11)
282f4ede81eSAmarnath Valluri #define PTM_CAP_SET_DATAFD         (1 << 12)
2839375c44fSStefan Berger #define PTM_CAP_SET_BUFFERSIZE     (1 << 13)
284efef4756SStefan Berger #define PTM_CAP_GET_INFO           (1 << 14)
285efef4756SStefan Berger #define PTM_CAP_SEND_COMMAND_HEADER (1 << 15)
286efef4756SStefan Berger #define PTM_CAP_LOCK_STORAGE       (1 << 16)
287f4ede81eSAmarnath Valluri 
288d1c637ecSBin Meng #ifndef _WIN32
289f4ede81eSAmarnath Valluri enum {
290f4ede81eSAmarnath Valluri     PTM_GET_CAPABILITY     = _IOR('P', 0, ptm_cap),
291f4ede81eSAmarnath Valluri     PTM_INIT               = _IOWR('P', 1, ptm_init),
292f4ede81eSAmarnath Valluri     PTM_SHUTDOWN           = _IOR('P', 2, ptm_res),
293f4ede81eSAmarnath Valluri     PTM_GET_TPMESTABLISHED = _IOR('P', 3, ptm_est),
294f4ede81eSAmarnath Valluri     PTM_SET_LOCALITY       = _IOWR('P', 4, ptm_loc),
295f4ede81eSAmarnath Valluri     PTM_HASH_START         = _IOR('P', 5, ptm_res),
296f4ede81eSAmarnath Valluri     PTM_HASH_DATA          = _IOWR('P', 6, ptm_hdata),
297f4ede81eSAmarnath Valluri     PTM_HASH_END           = _IOR('P', 7, ptm_res),
298f4ede81eSAmarnath Valluri     PTM_CANCEL_TPM_CMD     = _IOR('P', 8, ptm_res),
299f4ede81eSAmarnath Valluri     PTM_STORE_VOLATILE     = _IOR('P', 9, ptm_res),
300f4ede81eSAmarnath Valluri     PTM_RESET_TPMESTABLISHED = _IOWR('P', 10, ptm_reset_est),
301f4ede81eSAmarnath Valluri     PTM_GET_STATEBLOB      = _IOWR('P', 11, ptm_getstate),
302f4ede81eSAmarnath Valluri     PTM_SET_STATEBLOB      = _IOWR('P', 12, ptm_setstate),
303f4ede81eSAmarnath Valluri     PTM_STOP               = _IOR('P', 13, ptm_res),
304f4ede81eSAmarnath Valluri     PTM_GET_CONFIG         = _IOR('P', 14, ptm_getconfig),
305f4ede81eSAmarnath Valluri     PTM_SET_DATAFD         = _IOR('P', 15, ptm_res),
3069375c44fSStefan Berger     PTM_SET_BUFFERSIZE     = _IOWR('P', 16, ptm_setbuffersize),
307efef4756SStefan Berger     PTM_GET_INFO           = _IOWR('P', 17, ptm_getinfo),
308efef4756SStefan Berger     PTM_LOCK_STORAGE       = _IOWR('P', 18, ptm_lockstorage),
309f4ede81eSAmarnath Valluri };
310d1c637ecSBin Meng #endif
311f4ede81eSAmarnath Valluri 
312f4ede81eSAmarnath Valluri /*
313f4ede81eSAmarnath Valluri  * Commands used by the non-CUSE TPMs
314f4ede81eSAmarnath Valluri  *
315f4ede81eSAmarnath Valluri  * All messages container big-endian data.
316f4ede81eSAmarnath Valluri  *
317f4ede81eSAmarnath Valluri  * The return messages only contain the 'resp' part of the unions
318f4ede81eSAmarnath Valluri  * in the data structures above. Besides that the limits in the
319f4ede81eSAmarnath Valluri  * buffers above (ptm_hdata:u.req.data and ptm_get_state:u.resp.data
320f4ede81eSAmarnath Valluri  * and ptm_set_state:u.req.data) are 0xffffffff.
321f4ede81eSAmarnath Valluri  */
322f4ede81eSAmarnath Valluri enum {
323efef4756SStefan Berger     CMD_GET_CAPABILITY = 1,   /* 0x01 */
324efef4756SStefan Berger     CMD_INIT,                 /* 0x02 */
325efef4756SStefan Berger     CMD_SHUTDOWN,             /* 0x03 */
326efef4756SStefan Berger     CMD_GET_TPMESTABLISHED,   /* 0x04 */
327efef4756SStefan Berger     CMD_SET_LOCALITY,         /* 0x05 */
328efef4756SStefan Berger     CMD_HASH_START,           /* 0x06 */
329efef4756SStefan Berger     CMD_HASH_DATA,            /* 0x07 */
330efef4756SStefan Berger     CMD_HASH_END,             /* 0x08 */
331efef4756SStefan Berger     CMD_CANCEL_TPM_CMD,       /* 0x09 */
332efef4756SStefan Berger     CMD_STORE_VOLATILE,       /* 0x0a */
333efef4756SStefan Berger     CMD_RESET_TPMESTABLISHED, /* 0x0b */
334efef4756SStefan Berger     CMD_GET_STATEBLOB,        /* 0x0c */
335efef4756SStefan Berger     CMD_SET_STATEBLOB,        /* 0x0d */
336efef4756SStefan Berger     CMD_STOP,                 /* 0x0e */
337efef4756SStefan Berger     CMD_GET_CONFIG,           /* 0x0f */
338efef4756SStefan Berger     CMD_SET_DATAFD,           /* 0x10 */
339efef4756SStefan Berger     CMD_SET_BUFFERSIZE,       /* 0x11 */
340efef4756SStefan Berger     CMD_GET_INFO,             /* 0x12 */
341efef4756SStefan Berger     CMD_LOCK_STORAGE,         /* 0x13 */
342f4ede81eSAmarnath Valluri };
343f4ede81eSAmarnath Valluri 
344efef4756SStefan Berger #endif /* _TPM_IOCTL_H_ */
345