[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH] tpm: add stubs for qdev-prop-tpm
From: |
Cornelia Huck |
Subject: |
[Qemu-devel] [PATCH] tpm: add stubs for qdev-prop-tpm |
Date: |
Mon, 18 Dec 2017 13:16:35 +0100 |
Building with --disable-tpm yields
../hw/core/qdev-properties-system.o: In function `set_tpm':
/home/cohuck/git/qemu/hw/core/qdev-properties-system.c:274: undefined reference
to `qemu_find_tpm_be'
/home/cohuck/git/qemu/hw/core/qdev-properties-system.c:278: undefined reference
to `tpm_backend_init'
../hw/core/qdev-properties-system.o: In function `release_tpm':
/home/cohuck/git/qemu/hw/core/qdev-properties-system.c:291: undefined reference
to `tpm_backend_reset'
Add some proper stubs for those functions.
Fixes: 493b78303532 ("qdev: add DEFINE_PROP_TPMBE")
Reported-by: Thomas Huth <address@hidden>
Signed-off-by: Cornelia Huck <address@hidden>
---
stubs/tpm.c | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/stubs/tpm.c b/stubs/tpm.c
index c18aac1c73..97457e0646 100644
--- a/stubs/tpm.c
+++ b/stubs/tpm.c
@@ -7,6 +7,7 @@
#include "qemu/osdep.h"
#include "sysemu/tpm.h"
#include "qmp-commands.h"
+#include "sysemu/tpm_backend.h"
int tpm_init(void)
{
@@ -31,3 +32,17 @@ TpmModelList *qmp_query_tpm_models(Error **errp)
{
return NULL;
}
+
+TPMBackend *qemu_find_tpm_be(const char *id)
+{
+ return NULL;
+}
+
+int tpm_backend_init(TPMBackend *s, TPMIf *tpmif, Error **errp)
+{
+ return -1;
+}
+
+void tpm_backend_reset(TPMBackend *s)
+{
+}
--
2.13.6
- [Qemu-devel] [PATCH] tpm: add stubs for qdev-prop-tpm,
Cornelia Huck <=