mirror of
https://github.com/acidanthera/audk.git
synced 2025-04-07 19:45:07 +02:00
MdeModulePkg/DxeIpl: Remove clearing CR0.WP when protecting pagetable
Remove clearing CR0.WP when marking the memory used for page table as read-only in the page table itself created by DxeIpl. This page table address is written to Cr3 after these protection steps. Till this, the memory used for page table is always RW. Signed-off-by: Dun Tan <dun.tan@intel.com> Cc: Dandan Bi <dandan.bi@intel.com> Cc: Liming Gao <gaoliming@byosoft.com.cn> Reviewed-by: Ray Ni <ray.ni@intel.com>
This commit is contained in:
parent
7b4754904e
commit
62391b4ce9
@ -626,12 +626,7 @@ EnablePageTableProtection (
|
||||
}
|
||||
|
||||
//
|
||||
// Disable write protection, because we need to mark page table to be write
|
||||
// protected.
|
||||
//
|
||||
AsmWriteCr0 (AsmReadCr0 () & ~CR0_WP);
|
||||
|
||||
//
|
||||
// No need to clear CR0.WP since PageTableBase has't been written to CR3 yet.
|
||||
// SetPageTablePoolReadOnly might update mPageTablePool. It's safer to
|
||||
// remember original one in advance.
|
||||
//
|
||||
|
Loading…
x
Reference in New Issue
Block a user