3
TPM Device Driver Library interface
12
// --- This should be used on Windows platforms
14
#define TDDLI __declspec(dllexport)
16
#define TDDLI __declspec(dllimport)
23
// Errata: Change spec from TCPA_CAP_PROP_MANUFACTURER to TPM_CAP_PROP_MANUFACTURER
24
#define TDDL_CAP_VERSION 0x0100
25
#define TDDL_CAP_VER_DRV 0x0101
26
#define TDDL_CAP_VER_FW 0x0102
27
#define TDDL_CAP_VER_FW_DATE 0x0103
29
#define TDDL_CAP_PROPERTY 0x0200
30
#define TDDL_CAP_PROP_MANUFACTURER 0x0201
31
#define TDDL_CAP_PROP_MODULE_TYPE 0x0202
32
#define TDDL_CAP_PROP_GLOBAL_STATE 0x0203
34
//--------------------------------------------------------------------
35
// TDDL specific helper redefinitions
40
//establish a connection to the TPM device driver
41
TDDLI TSS_RESULT Tddli_Open();
43
//close a open connection to the TPM device driver
44
TDDLI TSS_RESULT Tddli_Close();
46
//cancels the last outstanding TPM command
47
TDDLI TSS_RESULT Tddli_Cancel();
49
// read the attributes returned by the TPM HW/FW
50
TDDLI TSS_RESULT Tddli_GetCapability(
57
// set parameters to the TPM HW/FW
58
TDDLI TSS_RESULT Tddli_SetCapability(
65
// get status of the TPM driver and device
66
TDDLI TSS_RESULT Tddli_GetStatus(
71
// send any data to the TPM module
72
TDDLI TSS_RESULT Tddli_TransmitData(
74
UINT32 TransmitBufLen,
76
UINT32* puntReceiveBufLen
81
//establish a connection to the TPM device driver
82
extern TDDLI TSS_RESULT Tddli_Open();
84
//close a open connection to the TPM device driver
85
extern TDDLI TSS_RESULT Tddli_Close();
87
//cancels the last outstanding TPM command
88
extern TDDLI TSS_RESULT Tddli_Cancel();
90
// read the attributes returned by the TPM HW/FW
91
extern TDDLI TSS_RESULT Tddli_GetCapability(
98
// set parameters to the TPM HW/FW
99
extern TDDLI TSS_RESULT Tddli_SetCapability(
106
// get status of the TPM driver and device
107
extern TDDLI TSS_RESULT Tddli_GetStatus(
108
UINT32 ReqStatusType,
112
// send any data to the TPM module
113
extern TDDLI TSS_RESULT Tddli_TransmitData(
115
UINT32 TransmitBufLen,
117
UINT32* puntReceiveBufLen
121
#endif // __TDDLI_H__