From: Stefan Berger <stefanb@linux.vnet.ibm.com>
To: qemu-devel@nongnu.org
Cc: amarnath.valluri@intel.com, marcandre.lureau@gmail.com,
Stefan Berger <stefanb@linux.vnet.ibm.com>
Subject: [Qemu-devel] [PATCH v2 0/7] tpm: Extend TPM with state migration support
Date: Fri, 27 Oct 2017 19:02:34 -0400 [thread overview]
Message-ID: <1509145361-11218-1-git-send-email-stefanb@linux.vnet.ibm.com> (raw)
This set of patches implements support for migrating the state of the
external 'swtpm' TPM emulator as well as that of the emulated device
interfaces. I have primarily tested this with TPM 1.2 so far, but it
also seems to work with TPM 2 and the CRB interface.
This series applies on top of Marc-Andre's patch set with all 42 patches
applied (21 of them have been applied).
One of the challenges that is addressed by this set of patches is the fact
that the TPM emulator may be processing a command while the state
serialization of the devices is supposed to happen. A necessary first step
has been implemented here that ensures that a response has been received
from the exernal emulator and the bottom half function, which delivers the
response and adjusts device registers (TIS or CRB), has been executed,
before the device's state is serialized.
A subsequent extension may need to address the live migration loop and delay
the serialization of devices until the response from the external TPM has
been received. Though the likelihood that someone executes a long-lasting
TPM command while this is occurring is certainly rare.
Stefan
Stefan Berger (7):
tpm: Introduce condition to notify waiters of completed command
tpm: Introduce condition in TPM backend for notification
tpm: implement tpm_backend_wait_cmd_completed
tpm: Implement tpm_sized_buffer_reset
tpm: extend TPM emulator with state migration support
tpm: extend TPM TIS with state migration support
tpm: extend TPM CRB with state migration support
backends/tpm.c | 29 ++++
hw/tpm/tpm_crb.c | 73 +++++++++-
hw/tpm/tpm_emulator.c | 309 +++++++++++++++++++++++++++++++++++++++++--
hw/tpm/tpm_tis.c | 151 +++++++++++++++++++--
hw/tpm/tpm_util.c | 7 +
hw/tpm/tpm_util.h | 7 +
include/sysemu/tpm_backend.h | 22 +++
7 files changed, 572 insertions(+), 26 deletions(-)
--
2.5.5
next reply other threads:[~2017-10-27 23:03 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-27 23:02 Stefan Berger [this message]
2017-10-27 23:02 ` [Qemu-devel] [PATCH v2 1/7] tpm: Introduce condition to notify waiters of completed command Stefan Berger
2017-10-27 23:02 ` [Qemu-devel] [PATCH v2 2/7] tpm: Introduce condition in TPM backend for notification Stefan Berger
2017-10-27 23:02 ` [Qemu-devel] [PATCH v2 3/7] tpm: implement tpm_backend_wait_cmd_completed Stefan Berger
2017-10-27 23:02 ` [Qemu-devel] [PATCH v2 4/7] tpm: Implement tpm_sized_buffer_reset Stefan Berger
2017-10-27 23:02 ` [Qemu-devel] [PATCH v2 5/7] tpm: extend TPM emulator with state migration support Stefan Berger
2017-10-27 23:02 ` [Qemu-devel] [PATCH v2 6/7] tpm: extend TPM TIS " Stefan Berger
2017-10-27 23:02 ` [Qemu-devel] [PATCH v2 7/7] tpm: extend TPM CRB " Stefan Berger
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=1509145361-11218-1-git-send-email-stefanb@linux.vnet.ibm.com \
--to=stefanb@linux.vnet.ibm.com \
--cc=amarnath.valluri@intel.com \
--cc=marcandre.lureau@gmail.com \
--cc=qemu-devel@nongnu.org \
/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).