qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH] tpm: Fix linker error when using --disable-tpm


From: Stefan Berger
Subject: [Qemu-devel] [PATCH] tpm: Fix linker error when using --disable-tpm
Date: Mon, 18 Dec 2017 09:07:58 -0500

Commit 493b7830 extends core/qdev-properties-system.c with a property
to lookup a TPM backend, which calls into TPM related functions.
Unfortunately this breaks the build when --disable-tpm is used. To
fix this we extend stubs/tpm.c with the missing stub functions.

Signed-off-by: Stefan Berger <address@hidden>
---
 stubs/tpm.c | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/stubs/tpm.c b/stubs/tpm.c
index c18aac1..bb1db44 100644
--- a/stubs/tpm.c
+++ b/stubs/tpm.c
@@ -6,6 +6,7 @@
  */
 #include "qemu/osdep.h"
 #include "sysemu/tpm.h"
+#include "sysemu/tpm_backend.h"
 #include "qmp-commands.h"
 
 int tpm_init(void)
@@ -31,3 +32,18 @@ TpmModelList *qmp_query_tpm_models(Error **errp)
 {
     return NULL;
 }
+
+void tpm_backend_reset(TPMBackend *s)
+{
+    return;
+}
+
+int tpm_backend_init(TPMBackend *s, TPMIf *tpmif, Error **errp)
+{
+    return 0;
+}
+
+TPMBackend *qemu_find_tpm_be(const char *id)
+{
+    return NULL;
+}
\ No newline at end of file
-- 
2.5.5




reply via email to

[Prev in Thread] Current Thread [Next in Thread]