// #### is Firmware Version 1\r
//\r
if (PnpHID) {\r
- AsciiSPrint(Hid + 3, TPM_HID_PNP_SIZE - 3, "%02d%02d", ((FirmwareVersion1 & 0xFFFF0000) >> 16), (FirmwareVersion1 && 0x0000FFFF));\r
+ AsciiSPrint(Hid + 3, TPM_HID_PNP_SIZE - 3, "%02d%02d", ((FirmwareVersion1 & 0xFFFF0000) >> 16), (FirmwareVersion1 & 0x0000FFFF));\r
} else {\r
- AsciiSPrint(Hid + 4, TPM_HID_ACPI_SIZE - 4, "%02d%02d", ((FirmwareVersion1 & 0xFFFF0000) >> 16), (FirmwareVersion1 && 0x0000FFFF));\r
+ AsciiSPrint(Hid + 4, TPM_HID_ACPI_SIZE - 4, "%02d%02d", ((FirmwareVersion1 & 0xFFFF0000) >> 16), (FirmwareVersion1 & 0x0000FFFF));\r
}\r
\r
} else {\r
{\r
EFI_INPUT_KEY Key;\r
UINT64 PcdTcg2PpiVersion;\r
+ UINT8 PcdTpm2AcpiTableRev;\r
\r
ASSERT (Action == EFI_BROWSER_ACTION_SUBMITTED);\r
\r
// Get the PCD value after EFI_BROWSER_ACTION_SUBMITTED,\r
// the SetVariable to TCG2_VERSION_NAME should have been done.\r
// If the PCD value is not equal to the value set to variable,\r
- // the PCD is not DynamicHii type and maps to the setup option.\r
+ // the PCD is not DynamicHii type and does not map to the setup option.\r
//\r
PcdTcg2PpiVersion = 0;\r
CopyMem (\r
&PcdTcg2PpiVersion,\r
PcdGetPtr (PcdTcgPhysicalPresenceInterfaceVer),\r
- AsciiStrSize (PcdGetPtr (PcdTcgPhysicalPresenceInterfaceVer))\r
+ AsciiStrSize ((CHAR8 *) PcdGetPtr (PcdTcgPhysicalPresenceInterfaceVer))\r
);\r
if (PcdTcg2PpiVersion != Value->u64) {\r
CreatePopUp (\r
EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,\r
&Key,\r
- L"WARNING: PcdTcgPhysicalPresenceInterfaceVer is not DynamicHii type and maps to this option!",\r
+ L"WARNING: PcdTcgPhysicalPresenceInterfaceVer is not DynamicHii type and does not map to this option!",\r
L"The version configuring by this setup option will not work!",\r
NULL\r
);\r
}\r
+ } else if (QuestionId == KEY_TPM2_ACPI_REVISION){\r
+ //\r
+ // Get the PCD value after EFI_BROWSER_ACTION_SUBMITTED,\r
+ // the SetVariable to TCG2_VERSION_NAME should have been done.\r
+ // If the PCD value is not equal to the value set to variable,\r
+ // the PCD is not DynamicHii type and does not map to the setup option.\r
+ //\r
+ PcdTpm2AcpiTableRev = PcdGet8 (PcdTpm2AcpiTableRev);\r
+\r
+ if (PcdTpm2AcpiTableRev != Value->u8) {\r
+ CreatePopUp (\r
+ EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,\r
+ &Key,\r
+ L"WARNING: PcdTpm2AcpiTableRev is not DynamicHii type and does not map to this option!",\r
+ L"The Revision configuring by this setup option will not work!",\r
+ NULL\r
+ );\r
+ }\r
}\r
\r
return EFI_SUCCESS;\r
}\r
\r
if (Action == EFI_BROWSER_ACTION_SUBMITTED) {\r
- if (QuestionId == KEY_TCG2_PPI_VERSION) {\r
+ if (QuestionId == KEY_TCG2_PPI_VERSION || QuestionId == KEY_TPM2_ACPI_REVISION) {\r
return Tcg2VersionInfoCallback (Action, QuestionId, Type, Value);\r
}\r
}\r
if (EFI_ERROR (Status)) {\r
DEBUG ((EFI_D_ERROR, "Tcg2ConfigDriver: Fail to set TCG2_STORAGE_INFO_NAME\n"));\r
}\r
+\r
return EFI_SUCCESS; \r
}\r
\r