diff --git a/Architecture/aarch64/Memory/VirtualMemoryManager.cpp b/Architecture/aarch64/Memory/VirtualMemoryManager.cpp
new file mode 100644
index 00000000..00c00e49
--- /dev/null
+++ b/Architecture/aarch64/Memory/VirtualMemoryManager.cpp
@@ -0,0 +1,40 @@
+/*
+ This file is part of Fennix Kernel.
+
+ Fennix Kernel is free software: you can redistribute it and/or
+ modify it under the terms of the GNU General Public License as
+ published by the Free Software Foundation, either version 3 of
+ the License, or (at your option) any later version.
+
+ Fennix Kernel is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with Fennix Kernel. If not, see .
+*/
+
+#include
+
+#include
+#include
+
+namespace Memory
+{
+ bool Virtual::Check(void *VirtualAddress, PTFlag Flag, MapType Type)
+ {
+ }
+
+ void *Virtual::GetPhysical(void *VirtualAddress)
+ {
+ }
+
+ void Virtual::Map(void *VirtualAddress, void *PhysicalAddress, uint64_t Flags, MapType Type)
+ {
+ }
+
+ void Virtual::Unmap(void *VirtualAddress, MapType Type)
+ {
+ }
+}
diff --git a/Architecture/aarch64/linker.ld b/Architecture/aarch64/linker.ld
index bb8c142e..0349abcc 100644
--- a/Architecture/aarch64/linker.ld
+++ b/Architecture/aarch64/linker.ld
@@ -19,6 +19,7 @@ ENTRY(_start)
SECTIONS
{
+ _bootstrap_start = .;
.text.boot :
{
*(.text.boot)
@@ -27,8 +28,10 @@ SECTIONS
*(.text.bss)
_bss_end = .;
}
+ _bootstrap_end = .;
_kernel_start = .;
+ _kernel_text_start = .;
.text :
{
KEEP(*(.text.boot))
@@ -37,6 +40,7 @@ SECTIONS
. = ALIGN(4096);
_kernel_text_end = .;
+ _kernel_data_start = .;
.data :
{
*(.data .data.*)
@@ -44,12 +48,12 @@ SECTIONS
. = ALIGN(4096);
_kernel_data_end = .;
+ _kernel_rodata_start = .;
.rodata :
{
*(.rodata .rodata.*)
}
. = ALIGN(4096);
- _kernel_rodata_end = .;
.init_array :
{
@@ -66,12 +70,15 @@ SECTIONS
KEEP(*(.fini_array .dtors))
PROVIDE_HIDDEN (__fini_array_end = .);
}
+ _kernel_rodata_end = .;
+ _kernel_bss_start = .;
.bss :
{
*(.bss .bss.*)
}
. = ALIGN(4096);
+ _kernel_bss_end = .;
_kernel_end = .;
_bss_size = _kernel_end - _kernel_rodata_end;
diff --git a/Kernel.cpp b/Kernel.cpp
index 33ca0600..e1029180 100644
--- a/Kernel.cpp
+++ b/Kernel.cpp
@@ -525,11 +525,7 @@ EXTERNC __no_stack_protector NIF void Entry(BootInfo *Info)
: "memory");
asmv("mov $0, %ebp");
#elif defined(aa64)
- asmv("mov %0, %%sp"
- :
- : "r"(KernelStack)
- : "memory");
- asmv("mov $0, %fp");
+#warning "Kernel stack is not set!"
#endif
#ifdef DEBUG
diff --git a/SystemCalls/Native.cpp b/SystemCalls/Native.cpp
index af975188..d23c4d1c 100644
--- a/SystemCalls/Native.cpp
+++ b/SystemCalls/Native.cpp
@@ -390,9 +390,11 @@ static int sys_fork(SyscallsFrame *Frame)
strncpy(NewThread->Name, Thread->Name, sizeof(Thread->Name));
NewThread->Info = Thread->Info;
+#ifdef a86
NewThread->ShadowGSBase = Thread->ShadowGSBase;
NewThread->GSBase = Thread->GSBase;
NewThread->FSBase = Thread->FSBase;
+#endif
CPU::Interrupts(CPU::Disable);
static int RetChild = 0;
diff --git a/include/syscalls.hpp b/include/syscalls.hpp
index 1d9f701a..419af1ea 100644
--- a/include/syscalls.hpp
+++ b/include/syscalls.hpp
@@ -59,6 +59,8 @@ typedef struct SyscallsFrame
uint32_t StackPointer;
uint32_t StackSegment;
#elif defined(aa64)
+ uint32_t ReturnAddress;
+ uint32_t StackPointer;
#endif
} SyscallsFrame;