summaryrefslogtreecommitdiffhomepage
path: root/src/kernel/HALKit/AMD64/HalKernelMain.cc
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@nekernel.org>2026-02-04 10:44:00 +0100
committerAmlal El Mahrouss <amlal@nekernel.org>2026-02-04 10:44:00 +0100
commit87aa249b33a68013b3a787c8d5c0ce880f8c4d84 (patch)
tree4d24891dbc4fa401d008aaf6c2b8a4b235b2c4cf /src/kernel/HALKit/AMD64/HalKernelMain.cc
parent30ba1aab88bd8138a6b3b3e1dbb464e4e67af698 (diff)
chore: kernel: Source code fixes and stabilization.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'src/kernel/HALKit/AMD64/HalKernelMain.cc')
-rw-r--r--src/kernel/HALKit/AMD64/HalKernelMain.cc16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/kernel/HALKit/AMD64/HalKernelMain.cc b/src/kernel/HALKit/AMD64/HalKernelMain.cc
index 0179732f..7e6579de 100644
--- a/src/kernel/HALKit/AMD64/HalKernelMain.cc
+++ b/src/kernel/HALKit/AMD64/HalKernelMain.cc
@@ -133,6 +133,14 @@ EXTERN_C Kernel::Int32 hal_init_platform(Kernel::HEL::BootInfoHeader* handover_h
}
EXTERN_C Kernel::Void hal_real_init(Kernel::Void) {
+ HAL::mp_init_cores(kHandoverHeader->f_HardwareTables.f_VendorPtr);
+
+ HAL::Register64 idt_reg;
+ idt_reg.Base = reinterpret_cast<UIntPtr>(kInterruptVectorTable);
+
+ HAL::IDTLoader idt_loader;
+ idt_loader.Load(idt_reg);
+
#ifdef __FSKIT_INCLUDES_OPENHEFS__
OpenHeFS::fs_init_openhefs();
HeFileSystemMgr::Mount(new HeFileSystemMgr());
@@ -149,13 +157,7 @@ EXTERN_C Kernel::Void hal_real_init(Kernel::Void) {
if (ldr.IsLoaded()) rtl_create_user_process(ldr, UserProcess::ExecutableKind::kExecutableKind);
- HAL::mp_init_cores(kHandoverHeader->f_HardwareTables.f_VendorPtr);
-
- HAL::Register64 idt_reg;
- idt_reg.Base = reinterpret_cast<UIntPtr>(kInterruptVectorTable);
-
- HAL::IDTLoader idt_loader;
- idt_loader.Load(idt_reg);
+ UserProcessScheduler::The().SwitchTeam(kMidUserTeam);
while (YES);
}