Re: [tpmdd-devel] [PATCH] tpm: don't destroy chip device prematurely

2016-10-04 Thread Jason Gunthorpe
On Tue, Oct 04, 2016 at 09:55:36PM +, Winkler, Tomas wrote: > > > On Tue, Oct 04, 2016 at 08:19:46AM +0300, Jarkko Sakkinen wrote: > > > > > > Make the driver uncallable first. The worst race that can happen is > > > > that open("/dev/tpm0", ...) returns -EPIPE. I do not consider this > > >

Re: [tpmdd-devel] [PATCH] tpm: don't destroy chip device prematurely

2016-10-04 Thread Winkler, Tomas
> On Tue, Oct 04, 2016 at 08:19:46AM +0300, Jarkko Sakkinen wrote: > > > > Make the driver uncallable first. The worst race that can happen is > > > that open("/dev/tpm0", ...) returns -EPIPE. I do not consider this > > > fatal at all. > > > > No responses for this reasonable proposal so I'll

Re: [tpmdd-devel] [PATCH v4 3/8] tpm: validate event log access before tpm_bios_log_setup

2016-10-04 Thread Jason Gunthorpe
On Tue, Oct 04, 2016 at 08:26:51AM +0300, Jarkko Sakkinen wrote: > On Mon, Oct 03, 2016 at 03:11:29PM -0600, Jason Gunthorpe wrote: > > On Mon, Oct 03, 2016 at 11:22:30PM +0300, Jarkko Sakkinen wrote: > > > > > > Sort of, the typical race is broadly > > > > > > > > CPU0

Re: [tpmdd-devel] [PATCH] tpm: don't destroy chip device prematurely

2016-10-04 Thread Jason Gunthorpe
On Tue, Oct 04, 2016 at 08:19:46AM +0300, Jarkko Sakkinen wrote: > > Make the driver uncallable first. The worst race that can happen is that > > open("/dev/tpm0", ...) returns -EPIPE. I do not consider this fatal at > > all. > > No responses for this reasonable proposal so I'll show what I