diff options
author | Claudio Carvalho <cclaudio@linux.vnet.ibm.com> | 2017-12-09 02:52:30 -0200 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2017-12-18 21:30:57 -0600 |
commit | 7da364fd3646013166b90baf26fc55078a446a21 (patch) | |
tree | c188bfef58d9ea7c0885efb2fd9bfa6e0318dbb9 /hdata/spira.h | |
parent | 48fd73cfc7073911a1ecdf0ff62e1800ef544d2a (diff) | |
download | skiboot-7da364fd3646013166b90baf26fc55078a446a21.zip skiboot-7da364fd3646013166b90baf26fc55078a446a21.tar.gz skiboot-7da364fd3646013166b90baf26fc55078a446a21.tar.bz2 |
hdata/tpmrel.c: add firmware event log info to the tpm node
This parses the firmware event log information from the
secureboot_tpm_info HDAT structure and add it to the tpm device tree
node.
There can be multiple secureboot_tpm_info entries with each entry
corresponding to a master processor that has a tpm device, however,
multiple tpm is not supported.
Signed-off-by: Claudio Carvalho <cclaudio@linux.vnet.ibm.com>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hdata/spira.h')
-rw-r--r-- | hdata/spira.h | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/hdata/spira.h b/hdata/spira.h index 17c6a2a..e2d45ab 100644 --- a/hdata/spira.h +++ b/hdata/spira.h @@ -1226,6 +1226,39 @@ struct ipmi_sensors { /* Idata index 1 : LED - sensors ID mapping data */ #define IPMI_SENSORS_IDATA_LED 1 +/* + * Node Secure and Trusted Boot Related Data + */ +#define STB_HDIF_SIG "TPMREL" + +/* + * Idata index 0 : Secure Boot and TPM Instance Info + * + * There can be multiple entries with each entry corresponding to + * a master processor that has a TPM device + */ +#define TPMREL_IDATA_SECUREBOOT_TPM_INFO 0 + +struct secureboot_tpm_info { + __be32 chip_id; + __be32 dbob_id; + uint8_t locality1; + uint8_t locality2; + uint8_t locality3; + uint8_t locality4; +#define TPM_PRESENT_AND_FUNCTIONAL 0x01 +#define TPM_PRESENT_AND_NOT_FUNCTIONAL 0x02 +#define TPM_NOT_PRESENT 0x03 + uint8_t tpm_status; + uint8_t reserved[3]; + /* zero indicates no tpm log data */ + __be32 srtm_log_offset; + __be32 srtm_log_size; + /* zero indicates no tpm log data */ + __be32 drtm_log_offset; + __be32 drtm_log_size; +} __packed; + static inline const char *cpu_state(u32 flags) { switch ((flags & CPU_ID_VERIFY_MASK) >> CPU_ID_VERIFY_SHIFT) { |