qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Berger <stefanb@linux.vnet.ibm.com>
To: qemu-devel@nongnu.org, thuth@redhat.com
Cc: peter.maydell@linaro.org, marcandre.lureau@redhat.com,
	Stefan Berger <stefanb@linux.vnet.ibm.com>
Subject: [Qemu-devel] [PATCH] tpm: Fix linker error when using --disable-tpm
Date: Mon, 18 Dec 2017 09:07:58 -0500	[thread overview]
Message-ID: <1513606078-728-1-git-send-email-stefanb@linux.vnet.ibm.com> (raw)

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 <stefanb@linux.vnet.ibm.com>
---
 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	other threads:[~2017-12-18 14:08 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-18 14:07 Stefan Berger [this message]
2017-12-18 15:49 ` [Qemu-devel] [PATCH] tpm: Fix linker error when using --disable-tpm no-reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1513606078-728-1-git-send-email-stefanb@linux.vnet.ibm.com \
    --to=stefanb@linux.vnet.ibm.com \
    --cc=marcandre.lureau@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=thuth@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).