1// This file was extracted from the TCG Published
2// Trusted Platform Module Library
3// Part 4: Supporting Routines
4// Family "2.0"
5// Level 00 Revision 01.16
6// October 30, 2014
7
8#define POWER_C
9#include "InternalRoutines.h"
10//          Functions
11//
12//           TPMInit()
13//
14//     This function is used to process a power on event.
15//
16void
17TPMInit(
18      void
19      )
20{
21      // Set state as not initialized. This means that Startup is required
22      s_initialized = FALSE;
23      return;
24}
25//
26//
27//           TPMRegisterStartup()
28//
29//     This function registers the fact that the TPM has been initialized (a TPM2_Startup() has completed
30//     successfully).
31//
32void
33TPMRegisterStartup(
34      void
35      )
36{
37      s_initialized = TRUE;
38      return;
39}
40//
41//
42//           TPMIsStarted()
43//
44//     Indicates if the TPM has been initialized (a TPM2_Startup() has completed successfully after a
45//     _TPM_Init()).
46//
47//     Return Value                    Meaning
48//
49//     TRUE                            TPM has been initialized
50//     FALSE                           TPM has not been initialized
51//
52BOOL
53TPMIsStarted(
54      void
55      )
56{
57      return s_initialized;
58}
59