Vadim Bendebury | 5679752 | 2015-05-20 10:32:25 -0700 | [diff] [blame] | 1 | // This file was extracted from the TCG Published |
| 2 | // Trusted Platform Module Library |
| 3 | // Part 3: Commands |
| 4 | // Family "2.0" |
| 5 | // Level 00 Revision 01.16 |
| 6 | // October 30, 2014 |
| 7 | |
| 8 | #include "InternalRoutines.h" |
| 9 | LIB_EXPORT void |
| 10 | _TPM_Init( |
| 11 | void |
| 12 | ) |
| 13 | { |
| 14 | // Clear the failure mode flags |
| 15 | g_inFailureMode = FALSE; |
| 16 | g_forceFailureMode = FALSE; |
| 17 | |
| 18 | // Initialize the NvEnvironment. |
| 19 | g_nvOk = NvPowerOn(); |
| 20 | |
| 21 | // Initialize crypto engine |
| 22 | CryptInitUnits(); |
| 23 | |
| 24 | // Start clock |
| 25 | TimePowerOn(); |
| 26 | |
| 27 | // Set initialization state |
| 28 | TPMInit(); |
| 29 | |
| 30 | // Initialize object table |
| 31 | ObjectStartup(); |
| 32 | |
| 33 | // Set g_DRTMHandle as unassigned |
| 34 | g_DRTMHandle = TPM_RH_UNASSIGNED; |
| 35 | |
| 36 | // No H-CRTM, yet. |
| 37 | g_DrtmPreStartup = FALSE; |
| 38 | |
| 39 | return; |
| 40 | } |