summaryrefslogtreecommitdiff
path: root/include/tpm_vendor_cmds.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/tpm_vendor_cmds.h')
-rw-r--r--include/tpm_vendor_cmds.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/tpm_vendor_cmds.h b/include/tpm_vendor_cmds.h
index a59c81e10f..3ad5d79214 100644
--- a/include/tpm_vendor_cmds.h
+++ b/include/tpm_vendor_cmds.h
@@ -165,6 +165,8 @@ enum vendor_cmd_cc {
*/
VENDOR_CC_DS_DIS_TEMP = 59,
+ VENDOR_CC_USER_PRES = 60,
+
LAST_VENDOR_COMMAND = 65535,
};
@@ -224,6 +226,18 @@ enum wp_options {
WP_ENABLE
};
+/* VENDOR_CC_USER_PRES options. */
+enum user_pres_options {
+ USER_PRES_ENABLE = BIT(0),
+ USER_PRES_DISABLE = BIT(1),
+ USER_PRES_PRESSED = BIT(2)
+};
+/* Structure for VENDOR_CC_USER_PRES response */
+struct user_pres_response {
+ uint8_t state; /* The user presence state. ENABLE or DISABLE */
+ uint64_t last_press; /* Time since last press */
+} __packed;
+
/*
* The TPMv2 Spec mandates that vendor-specific command codes have bit 29 set,
* while bits 15-0 indicate the command. All other bits should be zero.