On Wed, Nov 16, 2016 at 09:24:05AM -0500, Stefan Berger wrote: > The virtual TPM driver must not access the hosts's event log, > otherwise we get crashes from that. > > Signed-off-by: Stefan Berger <stef...@linux.vnet.ibm.com>
Can you give me a "Fixes" line (no need to send a new patch)? > --- > drivers/char/tpm/tpm_eventlog.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/drivers/char/tpm/tpm_eventlog.c b/drivers/char/tpm/tpm_eventlog.c > index fb603a7..e0abf40 100644 > --- a/drivers/char/tpm/tpm_eventlog.c > +++ b/drivers/char/tpm/tpm_eventlog.c > @@ -369,6 +369,9 @@ static int tpm_read_log(struct tpm_chip *chip) > { > int rc; > > + if (chip->flags & TPM_CHIP_FLAG_VIRTUAL) > + return -EFAULT; > + > if (chip->log.bios_event_log != NULL) { > dev_dbg(&chip->dev, > "%s: ERROR - event log already initialized\n", > -- > 2.4.3 > /Jarkko ------------------------------------------------------------------------------ _______________________________________________ tpmdd-devel mailing list tpmdd-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/tpmdd-devel