dmi_intel_rsd_tpm

Synopsis

#include <opendmi/entity/intel-rsd/tpm.h>
#include <opendmi/module/intel-rsd.h>

typedef struct dmi_intel_rsd_tpm {
    uint8_t config_index;
    const char *version;
    dmi_intel_rsd_tpm_status_t status;
} dmi_intel_rsd_tpm_t;

Description

The dmi_intel_rsd_tpm_t structure holds the decoded Trusted Platform Module (TPM) information structure (type 195) of Intel Rack Scale Design (RSD) firmware: one TPM configuration of the platform, with the version of the TPM and whether it is enabled. The pod manager selects the configuration to use by its index.

The structure is returned by dmi_entity_info for the structures of type DMI_TYPE(intel_rsd_tpm), once the Intel RSD extension module (dmi_intel_rsd_module, declared in <opendmi/module/intel-rsd.h>) has been enabled in the context with dmi_add_extension(). It lives as long as the context it has been decoded in.

Fields

config_index

One-based index of the configuration, the one the pod manager (PSME) passes to the IPMI Set TPM Configuration command to select it. The value.range lint rule reports a structure which holds 0.

version

Version of the TPM, nullptr if the structure does not carry it.

status

Whether the TPM is enabled (see dmi_intel_rsd_tpm_status).

Examples

dmi_registry_t      *registry = dmi_get_registry(context);
dmi_entity_t        *entity   = dmi_registry_lookup_first(registry,
                                    DMI_TYPE(intel_rsd_tpm), true);
dmi_intel_rsd_tpm_t *tpm      = dmi_entity_info(entity,
                                                DMI_TYPE(intel_rsd_tpm));

if (tpm != nullptr) {
    const char *status = dmi_intel_rsd_tpm_status_name(tpm->status);

    printf("TPM %s: %s\n",
           (tpm->version != nullptr) ? tpm->version : "unknown version",
           (status != nullptr) ? status : "unknown status");
}

Standards

Not part of the SMBIOS specification. Defined by Intel Rack Scale Design (RSD) firmware.