[U-Boot] [PATCH v5] tpm2: tis_spi: add the possibility to reset the chip with a gpio
Simon Glass
sjg at chromium.org
Wed May 16 15:40:12 UTC 2018
On 16 May 2018 at 16:59, Miquel Raynal <miquel.raynal at bootlin.com> wrote:
>
> On some designs, the reset line could not be connected to the SoC reset
> line, in this case, request the GPIO and ensure the chip gets reset.
>
> Signed-off-by: Miquel Raynal <miquel.raynal at bootlin.com>
> ---
>
> Changes since v4:
> =================
> * This patch was part of a bigger series, sending it alone as other
> files seems to be in an acceptable state now.
> * Changed the commit title with the prefix "tpm2: tis_spi:" to refer to
> the right file ("tpm:" is too generic now).
> * Removed the #ifdef CONFIG_DM_GPIO/#endif couple around the
> <.../gpio.h> include.
> * Changed the #ifdef CONFIG_DM_GPIO/#endif couple in the code by a
> if (IS_ENABLED(CONFIG_DM_GPIO)).
>
> Changes since v3:
> =================
> * Removed useless reset of rx_buf[0] in tpm_tis_spi_xfer().
> * Changed the way spi_xfer return code is checked: error out on any
> value != 0 instead of just negative ones.
> * Removed unused functions flagged __maybe_unused as well as well as the
> __maybe_unused flags themselves when not needed.
> * Simplified the validity check of the GPIO as suggested.
> * Updated the compatible property for the SPI modules (as well as the
> bindings docuementation) to be simply "tis,tpm2-spi" which should work
> with most compliant chips. Data is linked to this generic compatible
> in the TPM driver, other values may be added if needed in the future
> to fit other chips that would use different values than the current
> ones (used by Infineon SLB 9670 and ST ST33TPHF20 modules, for
> instance).
>
> drivers/tpm/tpm2_tis_spi.c | 16 ++++++++++++++++
> 1 file changed, 16 insertions(+)
Reviewed-by: Simon Glass <sjg at chromium.org>
More information about the U-Boot
mailing list