tpm_lite: stub: retry in case of TPM comm error
This CL retries reads and writes from/to TPM device if an error
is returned by read()/write(), up to 3 total attempts.
This is useful case of transient TPM communication errors that go
away after a single retry. Without this CL, after such errors the
encstateful key might be regenerated and encstateful data wiped.
TEST=1) normal boot still works;
2) simulate a single error, verify that it retries.
Commit-Ready: Andrey Pronin <email@example.com>
Tested-by: Andrey Pronin <firstname.lastname@example.org>
Reviewed-by: Andrey Pronin <email@example.com>
1 file changed