Commit bbf20d8
committed
Fix Tcg2SubmitCommand in TPM field upgrade scenario.
There's a bug that after the device was forced shut down during the tpm
firmware update process, then the TPM will stay in field upgrade mode and
refuse to work properly. This will block TPM startup and cause the device
to bootloop.
Now in the TCG_DXE_DATA struct we don’t have a flag to indicate the current
TPM mode, and we will simply treat the upper Scenario with this DEVICE_ERROR
and set the TPMPresentFlag to FALSE.
Later in Tcg2SubmitCommand we will just return DEVICE_ERROR and skip the
actual TPM recovery.
We should have an extra flag that check for the TPM response code and if
it's TPM_RC_UPGRADE, we knew the device is in field upgrade mode and should
continue the workflow.
We should only return EFI_DEVICE_ERROR when both TPMPresentFlag and
TpmUpdateFlag are false.
The field upgrade is part of TCG spec, and the capsule update/recovery
is part of UEFI spec.
Make this PR to bring in the fix for this corner case.
Signed-off-by: Liqi Qi <[email protected]>1 parent 49d4753 commit bbf20d8
1 file changed
+51
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
| 84 | + | |
84 | 85 | | |
85 | 86 | | |
86 | 87 | | |
| |||
101 | 102 | | |
102 | 103 | | |
103 | 104 | | |
| 105 | + | |
104 | 106 | | |
105 | 107 | | |
106 | 108 | | |
| |||
1407 | 1409 | | |
1408 | 1410 | | |
1409 | 1411 | | |
| 1412 | + | |
| 1413 | + | |
1410 | 1414 | | |
1411 | 1415 | | |
1412 | 1416 | | |
| |||
1415 | 1419 | | |
1416 | 1420 | | |
1417 | 1421 | | |
1418 | | - | |
1419 | | - | |
1420 | | - | |
1421 | | - | |
1422 | 1422 | | |
1423 | 1423 | | |
1424 | 1424 | | |
| |||
1427 | 1427 | | |
1428 | 1428 | | |
1429 | 1429 | | |
1430 | | - | |
1431 | | - | |
1432 | | - | |
1433 | | - | |
1434 | | - | |
1435 | | - | |
1436 | | - | |
| 1430 | + | |
| 1431 | + | |
| 1432 | + | |
| 1433 | + | |
| 1434 | + | |
| 1435 | + | |
| 1436 | + | |
| 1437 | + | |
| 1438 | + | |
| 1439 | + | |
| 1440 | + | |
| 1441 | + | |
| 1442 | + | |
| 1443 | + | |
| 1444 | + | |
| 1445 | + | |
| 1446 | + | |
| 1447 | + | |
| 1448 | + | |
| 1449 | + | |
| 1450 | + | |
| 1451 | + | |
| 1452 | + | |
| 1453 | + | |
| 1454 | + | |
| 1455 | + | |
| 1456 | + | |
| 1457 | + | |
| 1458 | + | |
| 1459 | + | |
| 1460 | + | |
| 1461 | + | |
| 1462 | + | |
| 1463 | + | |
| 1464 | + | |
| 1465 | + | |
| 1466 | + | |
| 1467 | + | |
| 1468 | + | |
| 1469 | + | |
| 1470 | + | |
| 1471 | + | |
| 1472 | + | |
| 1473 | + | |
| 1474 | + | |
| 1475 | + | |
| 1476 | + | |
1437 | 1477 | | |
1438 | 1478 | | |
1439 | 1479 | | |
| |||
0 commit comments