From mboxrd@z Thu Jan 1 00:00:00 1970 From: Miquel Raynal Date: Tue, 24 Apr 2018 15:02:30 +0200 Subject: [U-Boot] [PATCH v2 03/19] tpm: add support for TPMv2 SPI modules In-Reply-To: References: <20180329074401.8691-1-miquel.raynal@bootlin.com> <20180329074401.8691-4-miquel.raynal@bootlin.com> Message-ID: <20180424150230.111687ae@xps13> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: u-boot@lists.denx.de Hi Simon, On Fri, 30 Mar 2018 06:41:52 +0800, Simon Glass wrote: > Hi Miquel, >=20 > On 29 March 2018 at 15:43, Miquel Raynal wrot= e: > > Add the tpm_tis_spi driver that should support any TPMv2 compliant (SPI) > > module. > > > > Signed-off-by: Miquel Raynal > > --- > > drivers/tpm/Kconfig | 9 + > > drivers/tpm/Makefile | 1 + > > drivers/tpm/tpm_tis.h | 3 + > > drivers/tpm/tpm_tis_spi.c | 656 ++++++++++++++++++++++++++++++++++++++= ++++++++ > > 4 files changed, 669 insertions(+) > > create mode 100644 drivers/tpm/tpm_tis_spi.c =20 >=20 > I think this came up in another context. Would it make sense to create > a common interface to i2c and SPI and then have a common driver? I hesitated to do it (even started to write down some common code), and finally there was not so much of it, I was not sure if it would bring something more than obfuscation so I chose not to add an extra layer as I had currently only one SPI chip and no I2C chip to check the architecture. Maybe the question should be asked again when someone will want I2C support. Regards, Miqu=C3=A8l