From 333fed96b7ccd3ee4f5f097445408dde34d330db Mon Sep 17 00:00:00 2001 From: amlal Date: Thu, 21 Mar 2024 00:38:52 +0100 Subject: Kernel: See below. - Fix kernel heap, made it better. - Fix System.Core, made it better. Signed-off-by: amlal --- Private/HALKit/AMD64/HalInterruptRouting.asm | 17 +++-------------- Private/HALKit/AMD64/HalKernelMain.cxx | 3 ++- Private/HALKit/RISCV/Hart.hxx | 2 +- 3 files changed, 6 insertions(+), 16 deletions(-) (limited to 'Private/HALKit') diff --git a/Private/HALKit/AMD64/HalInterruptRouting.asm b/Private/HALKit/AMD64/HalInterruptRouting.asm index ae3d51c5..fe6fd2b5 100644 --- a/Private/HALKit/AMD64/HalInterruptRouting.asm +++ b/Private/HALKit/AMD64/HalInterruptRouting.asm @@ -111,16 +111,7 @@ __HCR_INT_33: push rax - mov rcx, kSystemCallLabelEnter - call ke_io_print - - pop rax - - push rax - - ;; Find and execute system call TODO - - mov rcx, kSystemCallLabelExit + mov rcx, kSystemCallLabel call ke_io_print pop rax @@ -228,9 +219,7 @@ kInterruptVectorTable: %assign i i+1 %endrep -kSystemCallLabelEnter: - db "HCoreKrnl.exe: SystemCall: Enter.", 0xa, 0xd, 0 -kSystemCallLabelExit: - db "HCoreKrnl.exe: SystemCall: Exit.", 0xa, 0xd, 0 +kSystemCallLabel: + db "HCoreKrnl.exe: SystemCall: Enter SCM.", 0xa, 0xd, 0 kMouseLabelExit: db "HCoreKrnl.exe: KernelMouse: Acknowledge Interrupt.", 0xa, 0xd, 0 \ No newline at end of file diff --git a/Private/HALKit/AMD64/HalKernelMain.cxx b/Private/HALKit/AMD64/HalKernelMain.cxx index 6c2ad263..abbf5feb 100644 --- a/Private/HALKit/AMD64/HalKernelMain.cxx +++ b/Private/HALKit/AMD64/HalKernelMain.cxx @@ -27,7 +27,7 @@ EXTERN_C void RuntimeMain( /// Setup kernel globals. kKernelVirtualSize = HandoverHeader->f_VirtualSize; - kKernelVirtualStart = HandoverHeader->f_VirtualStart; + kKernelVirtualStart = (HandoverHeader->f_VirtualStart + kVirtualAddressStartOffset); kKernelPhysicalSize = HandoverHeader->f_PhysicalSize; kKernelPhysicalStart = HandoverHeader->f_PhysicalStart; @@ -76,6 +76,7 @@ EXTERN_C void RuntimeMain( /// Mounts a NewFS block. HCore::FilesystemManagerInterface::Mount(new HCore::NewFilesystemManager()); + HCore::ke_delete_ke_heap(HCore::FilesystemManagerInterface::Unmount()); /// We already have an install of HCore. if (HandoverHeader->f_Bootloader == kInstalledMedia) { diff --git a/Private/HALKit/RISCV/Hart.hxx b/Private/HALKit/RISCV/Hart.hxx index f351d3e5..fbf7dca1 100644 --- a/Private/HALKit/RISCV/Hart.hxx +++ b/Private/HALKit/RISCV/Hart.hxx @@ -3,7 +3,7 @@ Copyright Mahrouss Logic File: Hart.hxx - Purpose: RISC-V hart abstraction. + Purpose: RISC-V hardware threads. Revision History: -- cgit v1.2.3