aboutsummaryrefslogtreecommitdiff
path: root/lib/tpm-v2.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2023-02-21 06:24:52 -0700
committerIlias Apalodimas <ilias.apalodimas@linaro.org>2023-02-28 09:44:33 +0200
commita11be4c303eabb142e074c7ca14b6ae0d293f0cb (patch)
tree99ebfce19f20a994bdc246bff46b39758675512e /lib/tpm-v2.c
parent4fef65715196364cb28ddbd7396b6015d78c778c (diff)
downloadu-boot-a11be4c303eabb142e074c7ca14b6ae0d293f0cb.zip
u-boot-a11be4c303eabb142e074c7ca14b6ae0d293f0cb.tar.gz
u-boot-a11be4c303eabb142e074c7ca14b6ae0d293f0cb.tar.bz2
tpm: Implement tpm_auto_start() for TPMv1.2
Add an implementation of this, moving the common call to tpm_init() up into the common API implementation. Add a test. Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org> Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Diffstat (limited to 'lib/tpm-v2.c')
-rw-r--r--lib/tpm-v2.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/lib/tpm-v2.c b/lib/tpm-v2.c
index 895b093..9ab5b46 100644
--- a/lib/tpm-v2.c
+++ b/lib/tpm-v2.c
@@ -48,14 +48,6 @@ u32 tpm2_auto_start(struct udevice *dev)
{
u32 rc;
- /*
- * the tpm_init() will return -EBUSY if the init has already happened
- * The selftest and startup code can run multiple times with no side
- * effects
- */
- rc = tpm_init(dev);
- if (rc && rc != -EBUSY)
- return rc;
rc = tpm2_self_test(dev, TPMI_YES);
if (rc == TPM2_RC_INITIALIZE) {