summary refs log tree commit diff stats
path: root/tests/qtest/tpm-util.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/qtest/tpm-util.h')
-rw-r--r--tests/qtest/tpm-util.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/qtest/tpm-util.h b/tests/qtest/tpm-util.h
index 15e3924942..3b97d69017 100644
--- a/tests/qtest/tpm-util.h
+++ b/tests/qtest/tpm-util.h
@@ -15,6 +15,11 @@
 
 #include "io/channel-socket.h"
 
+extern uint64_t tpm_tis_base_addr;
+
+#define TIS_REG(LOCTY, REG) \
+    (tpm_tis_base_addr + ((LOCTY) << 12) + REG)
+
 typedef void (tx_func)(QTestState *s,
                        const unsigned char *req, size_t req_size,
                        unsigned char *rsp, size_t rsp_size);