\r
PhysicalPresenceCallback() and MemoryClearCallback() will receive untrusted input and do some check.\r
\r
-Copyright (c) 2015 - 2016, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2015 - 2017, Intel Corporation. All rights reserved.<BR>\r
This program and the accompanying materials \r
are licensed and made available under the terms and conditions of the BSD License \r
which accompanies this distribution. The full text of the license may be found at \r
// Initialize HID with Default PNP string\r
//\r
ZeroMem(HID, TPM_HID_ACPI_SIZE);\r
- CopyMem(HID, TPM_HID_TAG, TPM_HID_PNP_SIZE);\r
\r
//\r
// Get Manufacturer ID\r
if (AsciiStrCmp((CHAR8 *)DataPtr, TPM_HID_TAG) == 0) {\r
if (PnpHID) {\r
CopyMem(DataPtr, HID, TPM_HID_PNP_SIZE);\r
- } else {\r
//\r
- // NOOP will be patched to '\0'\r
+ // if HID is PNP ID, patch the last byte in HID TAG to Noop\r
//\r
+ *(DataPtr + TPM_HID_PNP_SIZE) = AML_NOOP_OP;\r
+ } else {\r
+\r
CopyMem(DataPtr, HID, TPM_HID_ACPI_SIZE);\r
}\r
DEBUG((EFI_D_INFO, "TPM2 ACPI _HID updated to %a\n", HID));\r