From f99e383775fa43c5c1354067962b1590ff2abdae Mon Sep 17 00:00:00 2001 From: Amlal El Mahrouss Date: Sat, 3 Feb 2024 20:39:06 +0100 Subject: NewBoot: Will work on AHCI instead, ATA is not getting any further in the future. Signed-off-by: Amlal El Mahrouss --- Private/HALKit/PowerPC/HalHardware.cpp | 48 --------------------------------- Private/HALKit/PowerPC/HalHardware.cxx | 49 ++++++++++++++++++++++++++++++++++ 2 files changed, 49 insertions(+), 48 deletions(-) delete mode 100644 Private/HALKit/PowerPC/HalHardware.cpp create mode 100644 Private/HALKit/PowerPC/HalHardware.cxx (limited to 'Private/HALKit/PowerPC') diff --git a/Private/HALKit/PowerPC/HalHardware.cpp b/Private/HALKit/PowerPC/HalHardware.cpp deleted file mode 100644 index 96b2d09f..00000000 --- a/Private/HALKit/PowerPC/HalHardware.cpp +++ /dev/null @@ -1,48 +0,0 @@ -/* - * ======================================================== - * - * HCore - * Copyright Mahrouss Logic, all rights reserved. - * - * ======================================================== - */ - -#include -#include - -extern "C" void flush_tlb() {} -extern "C" void rt_wait_for_io() {} -extern "C" HCore::HAL::StackFrame* rt_get_current_context() {} - -namespace HCore { -namespace HAL { -UIntPtr hal_create_page(bool rw, bool user) { return 0; } - -UIntPtr hal_alloc_page(UIntPtr offset, bool rw, bool user) { return 0; } -} // namespace HAL - -// @brief wakes up thread. -// wakes up thread from hang. -void rt_wakeup_thread(HAL::StackFrame* stack) {} - -// @brief makes thread sleep. -// hooks and hangs thread to prevent code from executing. -void rt_hang_thread(HAL::StackFrame* stack) {} - -// @brief main HAL entrypoint -void ke_init_hal() {} - -void system_io_print(const char* bytes) { - if (!bytes) return; - - SizeT index = 0; - SizeT len = string_length(bytes, 256); - - while (index < len) { - // TODO - ++index; - } -} - -TerminalDevice kcout(HCore::system_io_print, nullptr); -} // namespace HCore diff --git a/Private/HALKit/PowerPC/HalHardware.cxx b/Private/HALKit/PowerPC/HalHardware.cxx new file mode 100644 index 00000000..550d3747 --- /dev/null +++ b/Private/HALKit/PowerPC/HalHardware.cxx @@ -0,0 +1,49 @@ +/* + * ======================================================== + * + * HCore + * Copyright Mahrouss Logic, all rights reserved. + * + * ======================================================== + */ + +#include +#include + +extern "C" void flush_tlb() {} +extern "C" void rt_wait_for_io() {} + +extern "C" HCore::HAL::StackFrame* rt_get_current_context() {} + +namespace HCore { +namespace HAL { +UIntPtr hal_create_page(bool rw, bool user) { return 0; } + +UIntPtr hal_alloc_page(UIntPtr offset, bool rw, bool user) { return 0; } +} // namespace HAL + +// @brief wakes up thread. +// wakes up thread from hang. +void rt_wakeup_thread(HAL::StackFrame* stack) {} + +// @brief makes thread sleep. +// hooks and hangs thread to prevent code from executing. +void rt_hang_thread(HAL::StackFrame* stack) {} + +// @brief main HAL entrypoint +void ke_init_hal() {} + +void ke_com_print(const char* bytes) { + if (!bytes) return; + + SizeT index = 0; + SizeT len = string_length(bytes, 256); + + while (index < len) { + // TODO + ++index; + } +} + +TerminalDevice kcout(HCore::ke_com_print, nullptr); +} // namespace HCore -- cgit v1.2.3