BOOLEAN PageTableSplitted;\r
\r
//\r
- // Don't mark page table as read-only if heap guard is enabled.\r
+ // Don't mark page table to read-only if heap guard is enabled.\r
//\r
// BIT2: SMM page guard enabled\r
// BIT3: SMM pool guard enabled\r
//\r
if ((PcdGet8 (PcdHeapGuardPropertyMask) & (BIT3 | BIT2)) != 0) {\r
+ DEBUG ((DEBUG_INFO, "Don't mark page table to read-only as heap guard is enabled\n"));\r
+ return ;\r
+ }\r
+\r
+ //\r
+ // Don't mark page table to read-only if SMM profile is enabled.\r
+ //\r
+ if (FeaturePcdGet (PcdCpuSmmProfileEnable)) {\r
+ DEBUG ((DEBUG_INFO, "Don't mark page table to read-only as SMM profile is enabled\n"));\r
return ;\r
}\r
\r