Re: [PATCH] tpm_tis_spi: Don't send anything during flow control

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

 



On Thu, Jun 04, 2020 at 06:48:58AM -0700, Doug Anderson wrote:
> Hi,
> 
> On Thu, Jun 4, 2020 at 2:40 AM Jarkko Sakkinen
> <jarkko.sakkinen@xxxxxxxxxxxxxxx> wrote:
> >
> > On Mon, Jun 01, 2020 at 03:54:03PM -0700, Doug Anderson wrote:
> > > Does that answer your question, or were you worried about us needing
> > > to init iobuf[0] to 0 in some other case?
> > >
> > > -Doug
> >
> > No, but it should be treated as a bug fix for CR50 implementation i.e.
> > for 797c0113c9a481d4554988d70b5b52fae657262f, or is there some reason
> > why it shouldn't?
> 
> As talked about in the commit message, I think this is a slight
> cleanup for non-Cr50 too.  Specifically if we end up running through
> the TPM_RETRY loop a second time we weren't re-initting "phy->iobuf[0]
> = 0;"  That means that the 2nd time through the loop we were actually
> sending the TPM back the byte that the TPM sent us the first time
> through the loop.
> 
> Presumably this doesn't matter much, but it still feels nicer not to
> be sending the TPM's bytes back to it when we're not really supposed
> to.
> 
> Also, as mentioned in the commit message, I haven't observed this
> fixing any problems.  I only came up with it from code inspection
> while trying to track something else down.

Thanks, I'm happy how it is.

Reviewed-by: Jarkko Sakkinen <jarkko.sakkinen@xxxxxxxxxxxxxxx>

/Jarkko



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux Kernel]     [Linux Kernel Hardening]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux