CHROMIUM: tpm: don't run self test during probe
authorLuigi Semenzato <semenzato@chromium.org>
Mon, 21 May 2012 20:34:16 +0000 (13:34 -0700)
committerOlof Johansson <olof@lixom.net>
Fri, 1 Jun 2012 06:55:28 +0000 (23:55 -0700)
commit3d8d9c7da4f5e31777a9fcb17682960f5eed183e
treef5f67ccace730380ddd9c1bd81216a2c7fc336c9
parent8a7ef4f1c35c3178f48f76afacfff4d5e57f121f
CHROMIUM: tpm: don't run self test during probe

The new version of the tpm_tis driver in kernel 3.4 runs
TPM_ContinueSelfTest in the probe function.  This is bad
in two ways.  1. If the self test has completed (which it
most likely has, since it starts automatically at power on
and lasts about 500ms) then this may start a new instance
of the selftest, and waits for it to complete, thus
delaying boot.  2. With our TPM, the command fails with
error code 0xa (BAD_ORDINAL) for unfathomable reasons.

I have sent mail to the trousers mailing list (where the
author of the TPM driver lurks) requesting some help in
understanding what goes on.  But in the meanwhile we
should apply this patch and move on.

BUG=chromium-os:31065
TEST=booted, verified that TPM works (stop tcsd, tpmc test, start tcsd)

Change-Id: I23c1f3acb3dd1b2e3149553b07fb633ac27e4aeb
Signed-off-by: Luigi Semenzato <semenzato@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/23148
Reviewed-by: Olof Johansson <olofj@chromium.org>
Reviewed-by: Will Drewry <wad@chromium.org>
drivers/char/tpm/tpm_tis.c