qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] acpi: Make TPM 2.0 with TIS available as MSFT01


From: Michael S. Tsirkin
Subject: Re: [Qemu-devel] [PATCH] acpi: Make TPM 2.0 with TIS available as MSFT0101
Date: Mon, 28 Jan 2019 10:56:51 -0500

On Mon, Jan 28, 2019 at 04:40:46PM +0100, Igor Mammedov wrote:
> On Mon, 28 Jan 2019 10:15:55 -0500
> "Michael S. Tsirkin" <address@hidden> wrote:
> 
> > On Mon, Jan 28, 2019 at 03:45:53PM +0100, Igor Mammedov wrote:
> > > On Fri, 25 Jan 2019 16:00:58 -0500
> > > Stefan Berger <address@hidden> wrote:
> > >   
> > > > This patch makes the a TPM 2.0 with TIS interface available under the
> > > > HID 'MSF0101'. This is supported by Linux and also Windows now  
> > > MSF0101 is relatively recent addition to Linux,
> > > are there in wild (old) kernels that worked with PNP0C31 but won't work
> > > with MSF0101?  
> > 
> > Well what would you do? You either have TPM 2.0 or you don't.
> > If you have a 2.0 backend you need to expose it as 2.0
> > to the frontend right?
> I wasn't clear enough, question is:
> If there are kernels where TPM2 worked with PNP0C31 and without MSF0101 
> support?

As far as I can see TPM 2.0 support was added by

commit 30fc8d138e9123f374a3c3867e7c7c5cd4004941
Author: Jarkko Sakkinen <address@hidden>
Date:   Fri Dec 12 11:46:39 2014 -0800

    tpm: TPM 2.0 CRB Interface

this seems to already use MSF0101.


I guess the answer is no.

>  
> > > > recognizes the TPM 2.0 with TIS interface. Leave the TPM 1.2 as before.
> > > > 
> > > > Signed-off-by: Stefan Berger <address@hidden>
> > > > ---
> > > >  hw/i386/acpi-build.c | 12 ++++++++++--
> > > >  1 file changed, 10 insertions(+), 2 deletions(-)
> > > > 
> > > > diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
> > > > index 2e21a31f82..f51225b4a7 100644
> > > > --- a/hw/i386/acpi-build.c
> > > > +++ b/hw/i386/acpi-build.c
> > > > @@ -2141,8 +2141,16 @@ build_dsdt(GArray *table_data, BIOSLinker 
> > > > *linker,
> > > >              build_append_pci_bus_devices(scope, bus, 
> > > > pm->pcihp_bridge_en);
> > > >  
> > > >              if (TPM_IS_TIS(tpm)) {
> > > > -                dev = aml_device("ISA.TPM");
> > > > -                aml_append(dev, aml_name_decl("_HID", 
> > > > aml_eisaid("PNP0C31")));
> > > > +                if (misc->tpm_version == TPM_VERSION_2_0) {
> > > > +                    dev = aml_device("TPM");
> > > > +                    aml_append(dev, aml_name_decl("_HID",
> > > > +                                                  
> > > > aml_string("MSFT0101")));
> > > > +                } else {
> > > > +                    dev = aml_device("ISA.TPM");
> > > > +                    aml_append(dev, aml_name_decl("_HID",
> > > > +                                                  
> > > > aml_eisaid("PNP0C31")));
> > > > +                }
> > > > +
> > > >                  aml_append(dev, aml_name_decl("_STA", aml_int(0xF)));
> > > >                  crs = aml_resource_template();
> > > >                  aml_append(crs, aml_memory32_fixed(TPM_TIS_ADDR_BASE,  



reply via email to

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