1 /* SPDX-License-Identifier: BSD-3-Clause */
3 #ifndef __VBOOT_SECDATA_TPM_PRIVATE_H__
4 #define __VBOOT_SECDATA_TPM_PRIVATE_H__
6 #include <console/console.h>
7 #include <security/tpm/tis.h>
10 #define VBDEBUG(format, args...) \
11 printk(BIOS_INFO, "%s():%d: " format, __func__, __LINE__, ## args)
13 #define RETURN_ON_FAILURE(tpm_cmd) do { \
15 if ((rc_ = (tpm_cmd)) != TPM_SUCCESS) { \
16 VBDEBUG("Antirollback: %08x returned by " #tpm_cmd "\n", \
22 tpm_result_t
safe_write(uint32_t index
, const void *data
, uint32_t length
);
24 tpm_result_t
factory_initialize_tpm1(struct vb2_context
*ctx
);
26 tpm_result_t
factory_initialize_tpm2(struct vb2_context
*ctx
);
28 #endif /* __VBOOT_SECDATA_TPM_PRIVATE_H__ */