Re: [PATCH] TPM: chip disabled state erronously being reported aserror

From: Paul Bolle
Date: Wed Apr 25 2012 - 05:41:53 EST


Rajiv,

On Tue, 2012-04-24 at 17:57 -0300, Rajiv Andrade wrote:
> Can you test it?

Sure. Your patch applied cleanly to the current Fedora 16 kernel's
sources (ie, kernel-3.3.2-6.fc16). One boot and one suspend-and-resume
cycle both were without the error message that bothered me so much.

That should be all testing that this patch needs, shouldn't it?

> tpm_do_selftest() attempts to read a PCR in order to
> decide if one can rely on the TPM being used or not.
> The function that's used by __tpm_pcr_read() does not
> expect the TPM to be disabled or deactivated, and if so,
> reports an error.
>
> It's fine if the TPM returns this error when trying to
> use it for the first time after a power cycle, but it's
> definitely not if it already returned success for a
> previous attempt to read one of its PCRs.
>
> The tpm_do_selftest() was modified so that the driver only
> reports this return code as an error when it really is.
>
> Reported-by: Paul Bolle <pebolle@xxxxxxxxxx>

I guess that is now "Reported-and-tested-by", even though the test was
run against a v3.3.2 based kernel.

> Signed-off-by: Rajiv Andrade <srajiv@xxxxxxxxxxxxxxxxxx>

Should this be CC-ed to stable for v3.3?


Paul Bolle

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/