OLD | NEW |
1 /* Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 1 /* Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
2 * Use of this source code is governed by a BSD-style license that can be | 2 * Use of this source code is governed by a BSD-style license that can be |
3 * found in the LICENSE file. | 3 * found in the LICENSE file. |
4 */ | 4 */ |
5 | 5 |
6 /* TPM Lightweight Command Library. | 6 /* TPM Lightweight Command Library. |
7 * | 7 * |
8 * A low-level library for interfacing to TPM hardware or an emulator. | 8 * A low-level library for interfacing to TPM hardware or an emulator. |
9 */ | 9 */ |
10 | 10 |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 uint32_t TlclContinueSelfTest(void); | 61 uint32_t TlclContinueSelfTest(void); |
62 | 62 |
63 /* Defines a space with permission [perm]. [index] is the index for the space, | 63 /* Defines a space with permission [perm]. [index] is the index for the space, |
64 * [size] the usable data size. The TPM error code is returned. | 64 * [size] the usable data size. The TPM error code is returned. |
65 */ | 65 */ |
66 uint32_t TlclDefineSpace(uint32_t index, uint32_t perm, uint32_t size); | 66 uint32_t TlclDefineSpace(uint32_t index, uint32_t perm, uint32_t size); |
67 | 67 |
68 /* Writes [length] bytes of [data] to space at [index]. The TPM error code is | 68 /* Writes [length] bytes of [data] to space at [index]. The TPM error code is |
69 * returned. | 69 * returned. |
70 */ | 70 */ |
71 uint32_t TlclWrite(uint32_t index, uint8_t *data, uint32_t length); | 71 uint32_t TlclWrite(uint32_t index, const void* data, uint32_t length); |
72 | 72 |
73 /* Reads [length] bytes from space at [index] into [data]. The TPM error code | 73 /* Reads [length] bytes from space at [index] into [data]. The TPM error code |
74 * is returned. | 74 * is returned. |
75 */ | 75 */ |
76 uint32_t TlclRead(uint32_t index, uint8_t *data, uint32_t length); | 76 uint32_t TlclRead(uint32_t index, void* data, uint32_t length); |
77 | 77 |
78 /* Write-locks space at [index]. The TPM error code is returned. | 78 /* Write-locks space at [index]. The TPM error code is returned. |
79 */ | 79 */ |
80 uint32_t TlclWriteLock(uint32_t index); | 80 uint32_t TlclWriteLock(uint32_t index); |
81 | 81 |
82 /* Read-locks space at [index]. The TPM error code is returned. | 82 /* Read-locks space at [index]. The TPM error code is returned. |
83 */ | 83 */ |
84 uint32_t TlclReadLock(uint32_t index); | 84 uint32_t TlclReadLock(uint32_t index); |
85 | 85 |
86 /* Asserts physical presence in software. The TPM error code is returned. | 86 /* Asserts physical presence in software. The TPM error code is returned. |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
128 | 128 |
129 /* Performs a TPM_Extend. | 129 /* Performs a TPM_Extend. |
130 */ | 130 */ |
131 uint32_t TlclExtend(int pcr_num, uint8_t* in_digest, uint8_t* out_digest); | 131 uint32_t TlclExtend(int pcr_num, uint8_t* in_digest, uint8_t* out_digest); |
132 | 132 |
133 /* Gets the permission bits for the NVRAM space with |index|. | 133 /* Gets the permission bits for the NVRAM space with |index|. |
134 */ | 134 */ |
135 uint32_t TlclGetPermissions(uint32_t index, uint32_t* permissions); | 135 uint32_t TlclGetPermissions(uint32_t index, uint32_t* permissions); |
136 | 136 |
137 #endif /* TPM_LITE_TLCL_H_ */ | 137 #endif /* TPM_LITE_TLCL_H_ */ |
OLD | NEW |