UefiCpuPkg/ResetVector: Simplify page table creation in ResetVector
Currently, page table creation has many hard-code values about the offset to the start of page table. To simplify it, add Labels such as Pml4, Pdp and Pd, so that we can remove many hard-code values Cc: Eric Dong <eric.dong@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com> Cc: Rahul Kumar <rahul1.kumar@intel.com> Tested-by: Gerd Hoffmann <kraxel@redhat.com> Acked-by: Gerd Hoffmann <kraxel@redhat.com> Cc: Debkumar De <debkumar.de@intel.com> Cc: Catharine West <catharine.west@intel.com> Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com>
This commit is contained in:
committed by
mergify[bot]
parent
cc62b85a4a
commit
c19e3f578f
@@ -2,7 +2,7 @@
|
||||
; @file
|
||||
; Sets the CR3 register for 64-bit paging
|
||||
;
|
||||
; Copyright (c) 2008 - 2013, Intel Corporation. All rights reserved.<BR>
|
||||
; Copyright (c) 2008 - 2023, Intel Corporation. All rights reserved.<BR>
|
||||
; SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
@@ -17,7 +17,7 @@ SetCr3ForPageTables64:
|
||||
;
|
||||
; These pages are built into the ROM image in X64/PageTables.asm
|
||||
;
|
||||
mov eax, ADDR_OF(TopLevelPageDirectory)
|
||||
mov eax, ADDR_OF(Pml4)
|
||||
mov cr3, eax
|
||||
|
||||
OneTimeCallRet SetCr3ForPageTables64
|
||||
|
Reference in New Issue
Block a user