From mboxrd@z Thu Jan 1 00:00:00 1970 From: Miquel Raynal Date: Wed, 7 Nov 2018 08:52:31 +0100 Subject: [U-Boot] [PATCH 17/25] tpm: Export the open/close functions In-Reply-To: <20181106222142.94537-18-sjg@chromium.org> References: <20181106222142.94537-1-sjg@chromium.org> <20181106222142.94537-18-sjg@chromium.org> Message-ID: <20181107085231.5fb99f27@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, Simon Glass wrote on Tue, 6 Nov 2018 15:21:34 -0700: > At present these functions are not accessible outside the TPM library, but > in some cases we need to call them. I was not aware, what is the use case? I don't get it. > Export them in the header file and add > a define for the SHA1 digest size. >=20 > Also adjust tpm_open() to call tpm_close() first so that the TPM is in a > known state before opening (e.g. by a previous phase of U-Boot). >=20 > Signed-off-by: Simon Glass > --- >=20 [...] > @@ -408,29 +435,12 @@ static int tpm_tis_lpc_open(struct udevice *dev) > return ret; > } > =20 > + /* Certain TPMs need some delay here or they hang */ > + udelay(10); > + > tpm_write_word(priv, TIS_STS_COMMAND_READY, > ®s[locality].tpm_status); This is not in the commit message. Perhaps, due to the nature of the changes, this patch would be best split in 2 or 3? Thanks, Miqu=C3=A8l