Re: [PATCH v4 2/6] tpm: tpm_tis_spi: Introduce a flow control callback

From: Jarkko Sakkinen
Date: Wed Aug 21 2019 - 14:13:13 EST


On Mon, Aug 19, 2019 at 10:06:40AM -0700, Stephen Boyd wrote:
> > AFAIK the flow control is not part of the SPI standard itself but is
> > proprietary for each slave device. Thus, the flow control should be
> > documented to the source code. I do not want flow control mechanisms to
> > be multiplied before this is done.
>
> Can you clarify this please? I don't understand what "the flow control
> should be documented to the source code" means.

Off the top of my head:

/* TCG SPI flow control is documented in the section 6.4 of [1]. However,
* Google's CR50 chip has its own proprietary flow control. This struct
* is used to bind the appropriate flow control mechanism.
*
* [1] https://trustedcomputinggroup.org/resource/pc-client-platform-tpm-profile-ptp-specification/
*/

> >
> > The magic number 0x01 would be also good to get rid off.
> >
>
> Ok. What name should the #define be? I can make that another patch.

Do nothing. Not part of your patch set scope, was a stupid comment from
my side.

/Jarkko