[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 22/42] tpm-backend: store TPMIf interface, impro
From: |
Marc-André Lureau |
Subject: |
Re: [Qemu-devel] [PATCH 22/42] tpm-backend: store TPMIf interface, improve backend_init() |
Date: |
Tue, 10 Oct 2017 07:02:05 -0400 (EDT) |
Hi
----- Original Message -----
> On Tue, 2017-10-10 at 00:56 +0200, Marc-André Lureau wrote:
> > Store the TPM interface, the actual object may be different from
> > TPMState. Keep a reference on the interface, and check the backend
> > wasn't already initialized.
> >
> > Signed-off-by: Marc-André Lureau <address@hidden>
> > ---
> > include/sysemu/tpm_backend.h | 7 ++++---
> > backends/tpm.c | 12 +++++++++---
> > hw/tpm/tpm_emulator.c | 4 ++--
> > hw/tpm/tpm_passthrough.c | 4 ++--
> > hw/tpm/tpm_tis.c | 2 +-
> > 5 files changed, 18 insertions(+), 11 deletions(-)
> >
> > diff --git a/include/sysemu/tpm_backend.h
> > b/include/sysemu/tpm_backend.h
> > index 03ea5a3400..8d08765b3c 100644
> > --- a/include/sysemu/tpm_backend.h
> > +++ b/include/sysemu/tpm_backend.h
> > @@ -18,6 +18,7 @@
> > #include "qapi-types.h"
> > #include "qemu/option.h"
> > #include "sysemu/tpm.h"
> > +#include "hw/tpm/tpm_int.h"
> This is not supposed to be internal header?
You are right, moving the interface to include/sysemu/tpm.h directly, to avoid
that header inclusion and later code churn in patch "tpm: lookup the the TPM
interface"
thanks
- [Qemu-devel] [PATCH 18/42] tpm-tis: remove tpm_tis.h header, (continued)
- [Qemu-devel] [PATCH 18/42] tpm-tis: remove tpm_tis.h header, Marc-André Lureau, 2017/10/09
- [Qemu-devel] [PATCH 19/42] tpm-tis: fold TPMTISEmuState in TPMState, Marc-André Lureau, 2017/10/09
- [Qemu-devel] [PATCH 20/42] tpm: add a QOM TPM interface, Marc-André Lureau, 2017/10/09
- [Qemu-devel] [PATCH 21/42] tpm: move recv_data_callback to TPM interface, Marc-André Lureau, 2017/10/09
- [Qemu-devel] [PATCH 22/42] tpm-backend: store TPMIf interface, improve backend_init(), Marc-André Lureau, 2017/10/09
- [Qemu-devel] [PATCH 23/42] tpm-tis: no longer expose TPMState, Marc-André Lureau, 2017/10/09
- [Qemu-devel] [PATCH 24/42] tpm-be: call request_completed() out of thread, Marc-André Lureau, 2017/10/09
- [Qemu-devel] [PATCH 25/42] tpm-be: report error instead of front-end, Marc-André Lureau, 2017/10/09
- [Qemu-devel] [PATCH 26/42] tpm-be: ask model to the TPM interface, Marc-André Lureau, 2017/10/09