From 38e87d52891429d56d20a54ce205d1e421068f36 Mon Sep 17 00:00:00 2001 From: Fabian Imhof Date: Sun, 27 Oct 2024 14:16:35 +0000 Subject: update gas --- arch/x86_64/src/boot/boot.s | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'arch/x86_64/src/boot/boot.s') diff --git a/arch/x86_64/src/boot/boot.s b/arch/x86_64/src/boot/boot.s index f04ae44..c1b3203 100644 --- a/arch/x86_64/src/boot/boot.s +++ b/arch/x86_64/src/boot/boot.s @@ -271,11 +271,6 @@ enable_paging: mov $page_map_level_4, %eax mov %eax, %cr3 - /* Map the P4 table recursively */ - mov $page_map_level_4, %eax - or 0b11, %eax /* Write present + writable flags into eax register */ - mov %eax, (page_map_level_4 + 511 * 8) - /* Enable Physical Address Extension */ mov %cr4, %eax or $(1 << 5), %eax @@ -317,6 +312,11 @@ enable_sse: * page map entries. */ prepare_page_maps: + /* Map the P4 table recursively */ + mov $page_map_level_4, %eax + or $0b11, %eax /* Write present + writable flags into eax register */ + mov %eax, (page_map_level_4 + 511 * 8) + /* Add an entry to the PML4, pointing to the PML3 */ mov $page_map_level_3, %eax or $0x3, %eax -- cgit v1.2.3