|
@@ -519,6 +519,11 @@ static inline void tpm_add_ppi(struct tpm_chip *chip)
|
|
|
}
|
|
|
#endif
|
|
|
|
|
|
+static inline inline u32 tpm2_rc_value(u32 rc)
|
|
|
+{
|
|
|
+ return (rc & BIT(7)) ? rc & 0xff : rc;
|
|
|
+}
|
|
|
+
|
|
|
int tpm2_pcr_read(struct tpm_chip *chip, int pcr_idx, u8 *res_buf);
|
|
|
int tpm2_pcr_extend(struct tpm_chip *chip, int pcr_idx, const u8 *hash);
|
|
|
int tpm2_get_random(struct tpm_chip *chip, u8 *out, size_t max);
|