[haiku-commits] Change in haiku[master]: efi/mmu: ensure sNextVirtualAddress is valid on 32-bit platforms

  • From: Gerrit <review@xxxxxxxxxxxxxxxxxxx>
  • To: waddlesplash <waddlesplash@xxxxxxxxx>, haiku-commits@xxxxxxxxxxxxx
  • Date: Fri, 21 Feb 2020 15:35:35 +0000

From Alex von Gluck IV <kallisti5@xxxxxxxxxxx>:

Alex von Gluck IV has uploaded this change for review. ( 
https://review.haiku-os.org/c/haiku/+/2258 ;)


Change subject: efi/mmu: ensure sNextVirtualAddress is valid on 32-bit platforms
......................................................................

efi/mmu: ensure sNextVirtualAddress is valid on 32-bit platforms

Change-Id: I1c762410860ac7a27cfc78345de3226e36195aba
---
M src/system/boot/platform/efi/mmu.cpp
1 file changed, 9 insertions(+), 1 deletion(-)



  git pull ssh://git.haiku-os.org:22/haiku refs/changes/58/2258/1

diff --git a/src/system/boot/platform/efi/mmu.cpp 
b/src/system/boot/platform/efi/mmu.cpp
index 037a73d..bf992e3 100644
--- a/src/system/boot/platform/efi/mmu.cpp
+++ b/src/system/boot/platform/efi/mmu.cpp
@@ -11,7 +11,7 @@
 #include <boot/addr_range.h>
 #include <boot/platform.h>
 #include <boot/stage2.h>
-#include <kernel/arch/x86/arch_kernel.h>
+#include <arch_kernel.h>
 #include <kernel/kernel.h>

 #include "efi_platform.h"
@@ -27,7 +27,15 @@
 };


+#if defined(KERNEL_LOAD_BASE_64_BIT)
 static addr_t sNextVirtualAddress = KERNEL_LOAD_BASE_64_BIT + 32 * 1024 * 1024;
+#elif defined(KERNEL_LOAD_BASE)
+static addr_t sNextVirtualAddress = KERNEL_LOAD_BASE + 32 * 1024 * 1024;
+#else
+#error Unable to find kernel load base on this architecture!
+#endif
+
+
 static allocated_memory_region *allocated_memory_regions = NULL;



--
To view, visit https://review.haiku-os.org/c/haiku/+/2258
To unsubscribe, or for help writing mail filters, visit 
https://review.haiku-os.org/settings

Gerrit-Project: haiku
Gerrit-Branch: master
Gerrit-Change-Id: I1c762410860ac7a27cfc78345de3226e36195aba
Gerrit-Change-Number: 2258
Gerrit-PatchSet: 1
Gerrit-Owner: Alex von Gluck IV <kallisti5@xxxxxxxxxxx>
Gerrit-MessageType: newchange

Other related posts:

  • » [haiku-commits] Change in haiku[master]: efi/mmu: ensure sNextVirtualAddress is valid on 32-bit platforms - Gerrit