mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2025-11-24 02:05:01 +00:00
Perform a full self test before one-time initialization.
Change-Id: I2f5232d5133c0725ec21f885a4632e980062be8f BUG=chrome-os-partner: 1826 TEST=none Review URL: http://codereview.chromium.org/6688004
This commit is contained in:
@@ -103,6 +103,15 @@ static uint32_t OneTimeInitializeTPM(RollbackSpaceFirmware* rsf,
|
|||||||
|
|
||||||
VBDEBUG(("TPM: One-time initialization\n"));
|
VBDEBUG(("TPM: One-time initialization\n"));
|
||||||
|
|
||||||
|
/* Do a full test. This only happens the first time the device is turned on
|
||||||
|
* in the factory, so performance is not an issue. This is almost certainly
|
||||||
|
* not necessary, but it gives us more confidence about some code paths below
|
||||||
|
* that are difficult to test---specifically the ones that set lifetime
|
||||||
|
* flags, and are only executed once per physical TPM. */
|
||||||
|
result = TlclSelfTestFull();
|
||||||
|
if (result != TPM_SUCCESS)
|
||||||
|
return result;
|
||||||
|
|
||||||
result = TlclGetPermanentFlags(&pflags);
|
result = TlclGetPermanentFlags(&pflags);
|
||||||
if (result != TPM_SUCCESS)
|
if (result != TPM_SUCCESS)
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
Reference in New Issue
Block a user