summaryrefslogtreecommitdiffhomepage
path: root/Private
diff options
context:
space:
mode:
Diffstat (limited to 'Private')
-rw-r--r--Private/ArchKit/ArchKit.hpp24
-rw-r--r--Private/Builtins/ACPI/ACPI.hxx4
-rw-r--r--Private/Builtins/ACPI/ACPIFactoryInterface.hxx4
-rw-r--r--Private/Builtins/AHCI/Defines.hxx310
-rw-r--r--Private/Builtins/ATA/Defines.hxx18
-rw-r--r--Private/Builtins/PS2/PS2MouseInterface.hxx4
-rw-r--r--Private/Builtins/README.TXT4
-rw-r--r--Private/Builtins/Toolbox/Toolbox.hxx12
-rw-r--r--Private/Builtins/Toolbox/Utils.hxx22
-rw-r--r--Private/Builtins/XHCI/Defines.hxx2
-rw-r--r--Private/CFKit/GUIDWizard.hpp6
-rw-r--r--Private/CFKit/GUIDWrapper.hpp4
-rw-r--r--Private/CFKit/IPCEndpoint.hxx4
-rw-r--r--Private/CFKit/Property.hpp4
-rw-r--r--Private/CFKit/URL.hpp4
-rw-r--r--Private/FSKit/HCFS.hxx46
-rw-r--r--Private/FSKit/IndexableProperty.hxx4
-rw-r--r--Private/FSKit/NewFS.hxx58
-rw-r--r--Private/FSKit/NewFSIteratorInterface.hxx4
-rw-r--r--Private/FirmwareKit/EFI/API.hxx2
-rw-r--r--Private/FirmwareKit/EFI/EFI.hxx4
-rw-r--r--Private/FirmwareKit/EPM.hxx38
-rw-r--r--Private/FirmwareKit/Handover.hxx4
-rw-r--r--Private/HALKit/AMD64/HalACPIFactoryInterface.cxx4
-rw-r--r--Private/HALKit/AMD64/HalCoreInterruptHandlerAMD64.cpp64
-rw-r--r--Private/HALKit/AMD64/HalCoreMultiProcessingAMD64.cpp4
-rw-r--r--Private/HALKit/AMD64/HalDebugOutput.cxx6
-rw-r--r--Private/HALKit/AMD64/HalDebugPort.cxx4
-rw-r--r--Private/HALKit/AMD64/HalDescriptorLoader.cpp10
-rw-r--r--Private/HALKit/AMD64/HalHardwareAPIC.cpp4
-rw-r--r--Private/HALKit/AMD64/HalInstallTIB.asm2
-rw-r--r--Private/HALKit/AMD64/HalKernelMain.cxx28
-rw-r--r--Private/HALKit/AMD64/HalKernelMouse.cxx30
-rw-r--r--Private/HALKit/AMD64/HalNewBoot.asm2
-rw-r--r--Private/HALKit/AMD64/HalPageAlloc.cpp6
-rw-r--r--Private/HALKit/AMD64/HalPageAlloc.hpp26
-rw-r--r--Private/HALKit/AMD64/HalProcessor.cpp4
-rw-r--r--Private/HALKit/AMD64/HalSMPCore.cxx6
-rw-r--r--Private/HALKit/AMD64/HalSMPCoreManager.asm2
-rw-r--r--Private/HALKit/AMD64/Hypervisor.hpp4
-rw-r--r--Private/HALKit/AMD64/PCI/Database.cxx2
-rw-r--r--Private/HALKit/AMD64/PCI/Device.cxx44
-rw-r--r--Private/HALKit/AMD64/PCI/Dma.cxx4
-rw-r--r--Private/HALKit/AMD64/PCI/Express.cxx2
-rw-r--r--Private/HALKit/AMD64/PCI/Iterator.cxx4
-rw-r--r--Private/HALKit/AMD64/Processor.hpp38
-rw-r--r--Private/HALKit/AMD64/Storage/ATA.cxx4
-rw-r--r--Private/HALKit/AXP/CoreSyscallHandlerDEC.cpp6
-rw-r--r--Private/HALKit/PowerPC/HalCoreSyscallHandlerPowerPC.cpp6
-rw-r--r--Private/HALKit/PowerPC/HalHardware.cxx4
-rw-r--r--Private/HALKit/PowerPC/HalThread.cxx2
-rw-r--r--Private/HALKit/PowerPC/Processor.hpp8
-rw-r--r--Private/HALKit/RISCV/Hart.hxx2
-rw-r--r--Private/KernelKit/CodeManager.hpp4
-rw-r--r--Private/KernelKit/DebugOutput.hpp4
-rw-r--r--Private/KernelKit/DeviceManager.hpp6
-rw-r--r--Private/KernelKit/DriveManager.hxx4
-rw-r--r--Private/KernelKit/FileManager.hpp6
-rw-r--r--Private/KernelKit/Framebuffer.hpp6
-rw-r--r--Private/KernelKit/HError.hpp10
-rw-r--r--Private/KernelKit/KernelHeap.hpp4
-rw-r--r--Private/KernelKit/LoaderInterface.hpp4
-rw-r--r--Private/KernelKit/LockDelegate.hpp4
-rw-r--r--Private/KernelKit/MSDOS.hpp12
-rw-r--r--Private/KernelKit/PCI/Database.hpp4
-rw-r--r--Private/KernelKit/PCI/Device.hpp8
-rw-r--r--Private/KernelKit/PCI/Dma.hpp4
-rw-r--r--Private/KernelKit/PCI/Dma.inl2
-rw-r--r--Private/KernelKit/PCI/IO-Impl-AMD64.inl4
-rw-r--r--Private/KernelKit/PCI/IO.hpp4
-rw-r--r--Private/KernelKit/PCI/Iterator.hpp4
-rw-r--r--Private/KernelKit/PCI/PCI.hpp4
-rw-r--r--Private/KernelKit/PE.hpp10
-rw-r--r--Private/KernelKit/PEF.hpp8
-rw-r--r--Private/KernelKit/PEFCodeManager.hxx4
-rw-r--r--Private/KernelKit/PEFSharedObject.hxx6
-rw-r--r--Private/KernelKit/PermissionSelector.hxx4
-rw-r--r--Private/KernelKit/ProcessScheduler.hpp6
-rw-r--r--Private/KernelKit/SMPManager.hpp4
-rw-r--r--Private/KernelKit/Semaphore.hpp2
-rw-r--r--Private/KernelKit/ThreadLocalStorage.hxx16
-rw-r--r--Private/KernelKit/ThreadLocalStorage.inl6
-rw-r--r--Private/KernelKit/Timer.hpp4
-rw-r--r--Private/KernelKit/UserHeap.hpp4
-rw-r--r--Private/NetworkKit/IP.hpp4
-rw-r--r--Private/NetworkKit/MAC.hxx4
-rw-r--r--Private/NetworkKit/NetworkDevice.hpp4
-rw-r--r--Private/NetworkKit/NetworkDevice.inl4
-rw-r--r--Private/NewBoot/BootKit/Arch/ATA.hxx2
-rw-r--r--Private/NewBoot/BootKit/Arch/SATA.hxx10
-rw-r--r--Private/NewBoot/BootKit/BootKit.hxx16
-rw-r--r--Private/NewBoot/Source/HEL/AMD64/BootEPM.cxx6
-rw-r--r--Private/NewBoot/Source/HEL/AMD64/BootString.cxx20
-rw-r--r--Private/NewBoot/Source/makefile2
-rw-r--r--Private/NewKit/Array.hpp4
-rw-r--r--Private/NewKit/ArrayList.hpp4
-rw-r--r--Private/NewKit/Atom.hpp4
-rw-r--r--Private/NewKit/Crc32.hpp6
-rw-r--r--Private/NewKit/Defines.hpp12
-rw-r--r--Private/NewKit/ErrorOr.hpp6
-rw-r--r--Private/NewKit/Function.hpp4
-rw-r--r--Private/NewKit/Json.hpp6
-rw-r--r--Private/NewKit/KernelCheck.hpp8
-rw-r--r--Private/NewKit/Macros.hpp8
-rw-r--r--Private/NewKit/MutableArray.hpp8
-rw-r--r--Private/NewKit/OwnPtr.hpp4
-rw-r--r--Private/NewKit/PageAllocator.hpp4
-rw-r--r--Private/NewKit/PageManager.hpp4
-rw-r--r--Private/NewKit/Pair.hpp4
-rw-r--r--Private/NewKit/Pmm.hpp4
-rw-r--r--Private/NewKit/Ref.hpp4
-rw-r--r--Private/NewKit/Stream.hpp4
-rw-r--r--Private/NewKit/String.hpp4
-rw-r--r--Private/NewKit/Utils.hpp4
-rw-r--r--Private/NewKit/Variant.hpp4
-rw-r--r--Private/ObjectKit/ObjectKit.hxx12
-rw-r--r--Private/Root/System/FileExplorerHome.html4
-rw-r--r--Private/Source/Crc32.cxx4
-rw-r--r--Private/Source/CxxAbi.cxx2
-rw-r--r--Private/Source/DriveManager.cxx2
-rw-r--r--Private/Source/FileManager.cxx6
-rw-r--r--Private/Source/Framebuffer.cxx10
-rw-r--r--Private/Source/GUIDWizard.cxx4
-rw-r--r--Private/Source/GUIDWrapper.cxx2
-rw-r--r--Private/Source/HError.cxx4
-rw-r--r--Private/Source/IndexableProperty.cxx4
-rw-r--r--Private/Source/Json.cxx4
-rw-r--r--Private/Source/KernelCheck.cxx12
-rw-r--r--Private/Source/KernelHeap.cxx4
-rw-r--r--Private/Source/Network/IP.cxx4
-rw-r--r--Private/Source/Network/NetworkDevice.cxx4
-rw-r--r--Private/Source/New+Delete.cxx10
-rw-r--r--Private/Source/NewFS+FileManager.cxx4
-rw-r--r--Private/Source/NewFS+IO.cxx2
-rw-r--r--Private/Source/NewFS+Journal.cxx6
-rw-r--r--Private/Source/PEFCodeManager.cxx4
-rw-r--r--Private/Source/PEFSharedObjectRT.cxx4
-rw-r--r--Private/Source/PRDT.cxx4
-rw-r--r--Private/Source/PageAllocator.cxx4
-rw-r--r--Private/Source/PageManager.cxx6
-rw-r--r--Private/Source/PermissionSelector.cxx6
-rw-r--r--Private/Source/Pmm.cxx4
-rw-r--r--Private/Source/ProcessScheduler.cxx4
-rw-r--r--Private/Source/ProcessTeam.cxx4
-rw-r--r--Private/Source/Property.cxx4
-rw-r--r--Private/Source/RuntimeMain.cxx6
-rw-r--r--Private/Source/SMPManager.cxx6
-rw-r--r--Private/Source/Semaphore.cxx4
-rw-r--r--Private/Source/Storage/AHCIDeviceInterface.cxx2
-rw-r--r--Private/Source/Storage/NVMEDeviceInterface.cxx4
-rw-r--r--Private/Source/String.cxx4
-rw-r--r--Private/Source/ThreadLocalStorage.cxx6
-rw-r--r--Private/Source/Timer.cxx2
-rw-r--r--Private/Source/URL.cxx4
-rw-r--r--Private/Source/UserHeap.cxx4
-rw-r--r--Private/Source/Utils.cxx8
-rw-r--r--Private/Source/Variant.cxx4
-rw-r--r--Private/StorageKit/AHCI.hpp4
-rw-r--r--Private/StorageKit/NVME.hpp4
-rw-r--r--Private/StorageKit/PRDT.hpp6
-rw-r--r--Private/StorageKit/Storage.hpp2
-rw-r--r--Private/StorageKit/StorageCore.inl4
-rw-r--r--Private/makefile2
163 files changed, 748 insertions, 748 deletions
diff --git a/Private/ArchKit/ArchKit.hpp b/Private/ArchKit/ArchKit.hpp
index e9e09577..c7130353 100644
--- a/Private/ArchKit/ArchKit.hpp
+++ b/Private/ArchKit/ArchKit.hpp
@@ -20,7 +20,7 @@
#error Unknown architecture
#endif
-namespace HCore {
+namespace NewOS {
constexpr static inline SSizeT rt_hash_seed(const char *seed, int mul) {
SSizeT hash = 0;
@@ -31,26 +31,26 @@ constexpr static inline SSizeT rt_hash_seed(const char *seed, int mul) {
return hash;
}
-} // namespace HCore
+} // namespace NewOS
#define kKernelMaxSystemCalls (256)
-typedef HCore::Void (*rt_syscall_proc)(HCore::HAL::StackFramePtr);
+typedef NewOS::Void (*rt_syscall_proc)(NewOS::HAL::StackFramePtr);
-extern HCore::Array<rt_syscall_proc,
+extern NewOS::Array<rt_syscall_proc,
kKernelMaxSystemCalls>
kSyscalls;
-EXTERN_C HCore::Void rt_wait_400ns();
-EXTERN_C HCore::HAL::StackFramePtr rt_get_current_context();
-EXTERN_C HCore::Void rt_do_context_switch(HCore::HAL::StackFramePtr stackFrame);
+EXTERN_C NewOS::Void rt_wait_400ns();
+EXTERN_C NewOS::HAL::StackFramePtr rt_get_current_context();
+EXTERN_C NewOS::Void rt_do_context_switch(NewOS::HAL::StackFramePtr stackFrame);
-inline HCore::VoidPtr kKernelVirtualStart;
-inline HCore::UIntPtr kKernelVirtualSize;
+inline NewOS::VoidPtr kKernelVirtualStart;
+inline NewOS::UIntPtr kKernelVirtualSize;
-inline HCore::VoidPtr kKernelPhysicalStart;
-inline HCore::UIntPtr kKernelPhysicalSize;
+inline NewOS::VoidPtr kKernelPhysicalStart;
+inline NewOS::UIntPtr kKernelPhysicalSize;
#include <FirmwareKit/Handover.hxx>
-inline HCore::HEL::HandoverInformationHeader* kHandoverHeader;
+inline NewOS::HEL::HandoverInformationHeader* kHandoverHeader;
diff --git a/Private/Builtins/ACPI/ACPI.hxx b/Private/Builtins/ACPI/ACPI.hxx
index c0076c5e..f0412b9e 100644
--- a/Private/Builtins/ACPI/ACPI.hxx
+++ b/Private/Builtins/ACPI/ACPI.hxx
@@ -13,7 +13,7 @@
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
class SDT {
public:
Char Signature[4];
@@ -62,6 +62,6 @@ class Address {
UInt8 Reserved;
UIntPtr Address;
};
-} // namespace HCore
+} // namespace NewOS
#endif // !__ACPI__
diff --git a/Private/Builtins/ACPI/ACPIFactoryInterface.hxx b/Private/Builtins/ACPI/ACPIFactoryInterface.hxx
index b81a8dde..6d2325fe 100644
--- a/Private/Builtins/ACPI/ACPIFactoryInterface.hxx
+++ b/Private/Builtins/ACPI/ACPIFactoryInterface.hxx
@@ -12,7 +12,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore {
+namespace NewOS {
class ACPIFactoryInterface final {
public:
explicit ACPIFactoryInterface(voidPtr rsdPtr);
@@ -47,6 +47,6 @@ class ACPIFactoryInterface final {
SSizeT m_Entries; // number of entries, -1 tells that no invalid entries were
// found.
};
-} // namespace HCore
+} // namespace NewOS
#endif // !__ACPI_MANAGER__
diff --git a/Private/Builtins/AHCI/Defines.hxx b/Private/Builtins/AHCI/Defines.hxx
index e1aa72ae..23c86049 100644
--- a/Private/Builtins/AHCI/Defines.hxx
+++ b/Private/Builtins/AHCI/Defines.hxx
@@ -45,168 +45,168 @@ typedef enum {
typedef struct FisRegH2D final {
// DWORD 0
- HCore::UInt8 fisType; // FIS_TYPE_REG_H2D
+ NewOS::UInt8 fisType; // FIS_TYPE_REG_H2D
- HCore::UInt8 portMul : 4; // Port multiplier
- HCore::UInt8 reserved0 : 3; // Reserved
- HCore::UInt8 cmdOrCtrl : 1; // 1: Command, 0: Control
+ NewOS::UInt8 portMul : 4; // Port multiplier
+ NewOS::UInt8 reserved0 : 3; // Reserved
+ NewOS::UInt8 cmdOrCtrl : 1; // 1: Command, 0: Control
- HCore::UInt8 command; // Command register
- HCore::UInt8 featurel; // Feature register, 7:0
+ NewOS::UInt8 command; // Command register
+ NewOS::UInt8 featurel; // Feature register, 7:0
// DWORD 1
- HCore::UInt8 lba0; // LBA low register, 7:0
- HCore::UInt8 lba1; // LBA mid register, 15:8
- HCore::UInt8 lba2; // LBA high register, 23:16
- HCore::UInt8 device; // Device register
+ NewOS::UInt8 lba0; // LBA low register, 7:0
+ NewOS::UInt8 lba1; // LBA mid register, 15:8
+ NewOS::UInt8 lba2; // LBA high register, 23:16
+ NewOS::UInt8 device; // Device register
// DWORD 2
- HCore::UInt8 lba3; // LBA register, 31:24
- HCore::UInt8 lba4; // LBA register, 39:32
- HCore::UInt8 lba5; // LBA register, 47:40
- HCore::UInt8 featureHigh; // Feature register, 15:8
+ NewOS::UInt8 lba3; // LBA register, 31:24
+ NewOS::UInt8 lba4; // LBA register, 39:32
+ NewOS::UInt8 lba5; // LBA register, 47:40
+ NewOS::UInt8 featureHigh; // Feature register, 15:8
// DWORD 3
- HCore::UInt8 countLow; // Count register, 7:0
- HCore::UInt8 countHigh; // Count register, 15:8
- HCore::UInt8 icc; // Isochronous command completion
- HCore::UInt8 control; // Control register
+ NewOS::UInt8 countLow; // Count register, 7:0
+ NewOS::UInt8 countHigh; // Count register, 15:8
+ NewOS::UInt8 icc; // Isochronous command completion
+ NewOS::UInt8 control; // Control register
// DWORD 4
- HCore::UInt8 reserved1[4]; // Reserved
+ NewOS::UInt8 reserved1[4]; // Reserved
} FisRegH2D;
typedef struct FisRegD2H final {
// DWORD 0
- HCore::UInt8 fisType; // FIS_TYPE_REG_D2H
+ NewOS::UInt8 fisType; // FIS_TYPE_REG_D2H
- HCore::UInt8 portMul : 4; // Port multiplier
- HCore::UInt8 reserved0 : 2; // Reserved
- HCore::UInt8 interruptBit : 1; // Interrupt bit
- HCore::UInt8 reserved1 : 1; // Reserved
+ NewOS::UInt8 portMul : 4; // Port multiplier
+ NewOS::UInt8 reserved0 : 2; // Reserved
+ NewOS::UInt8 interruptBit : 1; // Interrupt bit
+ NewOS::UInt8 reserved1 : 1; // Reserved
- HCore::UInt8 status; // Status register
- HCore::UInt8 error; // Error register
+ NewOS::UInt8 status; // Status register
+ NewOS::UInt8 error; // Error register
// DWORD 1
- HCore::UInt8 lba0; // LBA low register, 7:0
- HCore::UInt8 lba1; // LBA mid register, 15:8
- HCore::UInt8 lba2; // LBA high register, 23:16
- HCore::UInt8 device; // Device register
+ NewOS::UInt8 lba0; // LBA low register, 7:0
+ NewOS::UInt8 lba1; // LBA mid register, 15:8
+ NewOS::UInt8 lba2; // LBA high register, 23:16
+ NewOS::UInt8 device; // Device register
// DWORD 2
- HCore::UInt8 lba3; // LBA register, 31:24
- HCore::UInt8 lba4; // LBA register, 39:32
- HCore::UInt8 lba5; // LBA register, 47:40
- HCore::UInt8 rsv2; // Reserved
+ NewOS::UInt8 lba3; // LBA register, 31:24
+ NewOS::UInt8 lba4; // LBA register, 39:32
+ NewOS::UInt8 lba5; // LBA register, 47:40
+ NewOS::UInt8 rsv2; // Reserved
// DWORD 3
- HCore::UInt8 countLow; // Count register, 7:0
- HCore::UInt8 countHigh; // Count register, 15:8
- HCore::UInt8 rsv3[2]; // Reserved
+ NewOS::UInt8 countLow; // Count register, 7:0
+ NewOS::UInt8 countHigh; // Count register, 15:8
+ NewOS::UInt8 rsv3[2]; // Reserved
// DWORD 4
- HCore::UInt8 rsv4[4]; // Reserved
+ NewOS::UInt8 rsv4[4]; // Reserved
} FisRegD2H;
typedef struct FisData final {
// DWORD 0
- HCore::UInt8 fisType; // FIS_TYPE_DATA
+ NewOS::UInt8 fisType; // FIS_TYPE_DATA
- HCore::UInt8 portMul : 4; // Port multiplier
- HCore::UInt8 reserved0 : 4; // Reserved
+ NewOS::UInt8 portMul : 4; // Port multiplier
+ NewOS::UInt8 reserved0 : 4; // Reserved
- HCore::UInt8 reserved1[2]; // Reserved
+ NewOS::UInt8 reserved1[2]; // Reserved
// DWORD 1 ~ N
- HCore::UInt32 data[1]; // Payload
+ NewOS::UInt32 data[1]; // Payload
} FisData;
typedef struct FisPioSetup final {
// DWORD 0
- HCore::UInt8 fisType; // FIS_TYPE_PIO_SETUP
+ NewOS::UInt8 fisType; // FIS_TYPE_PIO_SETUP
- HCore::UInt8 portMul : 4; // Port multiplier
- HCore::UInt8 reserved0 : 1; // Reserved
- HCore::UInt8 d : 1; // Data transfer direction, 1 - device to host
- HCore::UInt8 interruptBit : 1; // Interrupt bit
- HCore::UInt8 reserved1 : 1;
+ NewOS::UInt8 portMul : 4; // Port multiplier
+ NewOS::UInt8 reserved0 : 1; // Reserved
+ NewOS::UInt8 d : 1; // Data transfer direction, 1 - device to host
+ NewOS::UInt8 interruptBit : 1; // Interrupt bit
+ NewOS::UInt8 reserved1 : 1;
- HCore::UInt8 status; // Status register
- HCore::UInt8 error; // Error register
+ NewOS::UInt8 status; // Status register
+ NewOS::UInt8 error; // Error register
// DWORD 1
- HCore::UInt8 lba0; // LBA low register, 7:0
- HCore::UInt8 lba1; // LBA mid register, 15:8
- HCore::UInt8 lba2; // LBA high register, 23:16
- HCore::UInt8 device; // Device register
+ NewOS::UInt8 lba0; // LBA low register, 7:0
+ NewOS::UInt8 lba1; // LBA mid register, 15:8
+ NewOS::UInt8 lba2; // LBA high register, 23:16
+ NewOS::UInt8 device; // Device register
// DWORD 2
- HCore::UInt8 lba3; // LBA register, 31:24
- HCore::UInt8 lba4; // LBA register, 39:32
- HCore::UInt8 lba5; // LBA register, 47:40
- HCore::UInt8 rsv2; // Reserved
+ NewOS::UInt8 lba3; // LBA register, 31:24
+ NewOS::UInt8 lba4; // LBA register, 39:32
+ NewOS::UInt8 lba5; // LBA register, 47:40
+ NewOS::UInt8 rsv2; // Reserved
// DWORD 3
- HCore::UInt8 countLow; // Count register, 7:0
- HCore::UInt8 countHigh; // Count register, 15:8
- HCore::UInt8 rsv3; // Reserved
- HCore::UInt8 eStatus; // New value of status register
+ NewOS::UInt8 countLow; // Count register, 7:0
+ NewOS::UInt8 countHigh; // Count register, 15:8
+ NewOS::UInt8 rsv3; // Reserved
+ NewOS::UInt8 eStatus; // New value of status register
// DWORD 4
- HCore::UInt16 tc; // Transfer count
- HCore::UInt8 rsv4[2]; // Reserved
+ NewOS::UInt16 tc; // Transfer count
+ NewOS::UInt8 rsv4[2]; // Reserved
} FisPioSetup;
typedef struct FisDmaSetup final {
// DWORD 0
- HCore::UInt8 fisType; // FIS_TYPE_DMA_SETUP
+ NewOS::UInt8 fisType; // FIS_TYPE_DMA_SETUP
- HCore::UInt8 portMul : 4; // Port multiplier
- HCore::UInt8 reserved0 : 1; // Reserved
- HCore::UInt8 dtd : 1; // Data transfer direction, 1 - device to host
- HCore::UInt8 interruptBit : 1; // Interrupt bit
- HCore::UInt8
+ NewOS::UInt8 portMul : 4; // Port multiplier
+ NewOS::UInt8 reserved0 : 1; // Reserved
+ NewOS::UInt8 dtd : 1; // Data transfer direction, 1 - device to host
+ NewOS::UInt8 interruptBit : 1; // Interrupt bit
+ NewOS::UInt8
autoEnable : 1; // Auto-activate. Specifies if DMA Activate FIS is needed
- HCore::UInt8 reserved1[2]; // Reserved
+ NewOS::UInt8 reserved1[2]; // Reserved
// DWORD 1&2
- HCore::UInt64 dmaBufferId; // DMA Buffer Identifier. Used to Identify DMA buffer in
+ NewOS::UInt64 dmaBufferId; // DMA Buffer Identifier. Used to Identify DMA buffer in
// host memory. SATA Spec says host specific and not in
// Spec. Trying AHCI spec might work.
// DWORD 3
- HCore::UInt32 rsvd; // More reserved
+ NewOS::UInt32 rsvd; // More reserved
// DWORD 4
- HCore::UInt32 dmabufOffset; // Byte offset into buffer. First 2 bits must be 0
+ NewOS::UInt32 dmabufOffset; // Byte offset into buffer. First 2 bits must be 0
// DWORD 5
- HCore::UInt32 transferCount; // Number of bytes to transfer. Bit 0 must be 0
+ NewOS::UInt32 transferCount; // Number of bytes to transfer. Bit 0 must be 0
// DWORD 6
- HCore::UInt32 reserved3; // Reserved
+ NewOS::UInt32 reserved3; // Reserved
} FisDmaSetup;
typedef struct FisDevBits final {
// DWORD 0
- HCore::UInt8 fisType; // FIS_TYPE_DMA_SETUP (A1h)
+ NewOS::UInt8 fisType; // FIS_TYPE_DMA_SETUP (A1h)
- HCore::UInt8 reserved0 : 5; // Reserved
- HCore::UInt8 r0 : 1;
- HCore::UInt8 interruptBit : 1;
- HCore::UInt8 n : 1;
+ NewOS::UInt8 reserved0 : 5; // Reserved
+ NewOS::UInt8 r0 : 1;
+ NewOS::UInt8 interruptBit : 1;
+ NewOS::UInt8 n : 1;
- HCore::UInt8 statusLow : 3;
- HCore::UInt8 r1 : 1;
- HCore::UInt8 statusHigh : 3;
+ NewOS::UInt8 statusLow : 3;
+ NewOS::UInt8 r1 : 1;
+ NewOS::UInt8 statusHigh : 3;
- HCore::UInt8 r2 : 1;
- HCore::UInt8 error;
+ NewOS::UInt8 r2 : 1;
+ NewOS::UInt8 error;
// DWORD 1
- HCore::UInt32 act;
+ NewOS::UInt32 act;
} FisDevBits;
/// \brief Enable AHCI device bit in GHC register.
@@ -215,101 +215,101 @@ typedef struct FisDevBits final {
#endif //! ifndef kAhciGHC_AE
typedef struct HbaPort final {
- HCore::UInt32 clb; // 0x00, command list base address, 1K-byte aligned
- HCore::UInt32 clbu; // 0x04, command list base address upper 32 bits
- HCore::UInt32 fb; // 0x08, FIS base address, 256-byte aligned
- HCore::UInt32 fbu; // 0x0C, FIS base address upper 32 bits
- HCore::UInt32 is; // 0x10, interrupt status
- HCore::UInt32 ie; // 0x14, interrupt enable
- HCore::UInt32 cmd; // 0x18, command and status
- HCore::UInt32 reserved0; // 0x1C, Reserved
- HCore::UInt32 tfd; // 0x20, task file data
- HCore::UInt32 sig; // 0x24, signature
- HCore::UInt32 ssts; // 0x28, SATA status (SCR0:SStatus)
- HCore::UInt32 sctl; // 0x2C, SATA control (SCR2:SControl)
- HCore::UInt32 serr; // 0x30, SATA error (SCR1:SError)
- HCore::UInt32 sact; // 0x34, SATA active (SCR3:SActive)
- HCore::UInt32 ci; // 0x38, command issue
- HCore::UInt32 sntf; // 0x20, SATA notification (SCR4:SNotification)
- HCore::UInt32 fbs; // 0x40, FIS-based switch control
- HCore::UInt32 reserved1[11]; // 0x44 ~ 0x6F, Reserved
- HCore::UInt32 vendor[4]; // 0x70 ~ 0x7F, vendor specific
+ NewOS::UInt32 clb; // 0x00, command list base address, 1K-byte aligned
+ NewOS::UInt32 clbu; // 0x04, command list base address upper 32 bits
+ NewOS::UInt32 fb; // 0x08, FIS base address, 256-byte aligned
+ NewOS::UInt32 fbu; // 0x0C, FIS base address upper 32 bits
+ NewOS::UInt32 is; // 0x10, interrupt status
+ NewOS::UInt32 ie; // 0x14, interrupt enable
+ NewOS::UInt32 cmd; // 0x18, command and status
+ NewOS::UInt32 reserved0; // 0x1C, Reserved
+ NewOS::UInt32 tfd; // 0x20, task file data
+ NewOS::UInt32 sig; // 0x24, signature
+ NewOS::UInt32 ssts; // 0x28, SATA status (SCR0:SStatus)
+ NewOS::UInt32 sctl; // 0x2C, SATA control (SCR2:SControl)
+ NewOS::UInt32 serr; // 0x30, SATA error (SCR1:SError)
+ NewOS::UInt32 sact; // 0x34, SATA active (SCR3:SActive)
+ NewOS::UInt32 ci; // 0x38, command issue
+ NewOS::UInt32 sntf; // 0x20, SATA notification (SCR4:SNotification)
+ NewOS::UInt32 fbs; // 0x40, FIS-based switch control
+ NewOS::UInt32 reserved1[11]; // 0x44 ~ 0x6F, Reserved
+ NewOS::UInt32 vendor[4]; // 0x70 ~ 0x7F, vendor specific
} HbaPort;
typedef struct HbaMem final {
// 0x00 - 0x2B, Generic Host Control
- HCore::UInt32 cap; // 0x00, Host capability
- HCore::UInt32 ghc; // 0x04, Global host control
- HCore::UInt32 is; // 0x08, Interrupt status
- HCore::UInt32 pi; // 0x0C, Port implemented
- HCore::UInt32 vs; // 0x10, Version
- HCore::UInt32 ccc_ctl; // 0x14, Command completion coalescing control
- HCore::UInt32 ccc_pts; // 0x18, Command completion coalescing ports
- HCore::UInt32 em_loc; // 0x1C, Enclosure management location
- HCore::UInt32 em_ctl; // 0x20, Enclosure management control
- HCore::UInt32 cap2; // 0x24, Host capabilities extended
- HCore::UInt32 bohc; // 0x28, BIOS/OS handoff control and status
-
- HCore::UInt16 rsv;
- HCore::UInt32 resv2;
+ NewOS::UInt32 cap; // 0x00, Host capability
+ NewOS::UInt32 ghc; // 0x04, Global host control
+ NewOS::UInt32 is; // 0x08, Interrupt status
+ NewOS::UInt32 pi; // 0x0C, Port implemented
+ NewOS::UInt32 vs; // 0x10, Version
+ NewOS::UInt32 ccc_ctl; // 0x14, Command completion coalescing control
+ NewOS::UInt32 ccc_pts; // 0x18, Command completion coalescing ports
+ NewOS::UInt32 em_loc; // 0x1C, Enclosure management location
+ NewOS::UInt32 em_ctl; // 0x20, Enclosure management control
+ NewOS::UInt32 cap2; // 0x24, Host capabilities extended
+ NewOS::UInt32 bohc; // 0x28, BIOS/OS handoff control and status
+
+ NewOS::UInt16 rsv;
+ NewOS::UInt32 resv2;
HbaPort ports[1]; // 1 ~ 32
} HbaMem;
typedef struct HbaCmdHeader final {
// DW0
- HCore::UInt8 cfl : 5; // Command FIS length in DWORDS, 2 ~ 16
- HCore::UInt8 atapi : 1; // ATAPI
- HCore::UInt8 write : 1; // Write, 1: H2D, 0: D2H
- HCore::UInt8 prefetchable : 1; // Prefetchable
+ NewOS::UInt8 cfl : 5; // Command FIS length in DWORDS, 2 ~ 16
+ NewOS::UInt8 atapi : 1; // ATAPI
+ NewOS::UInt8 write : 1; // Write, 1: H2D, 0: D2H
+ NewOS::UInt8 prefetchable : 1; // Prefetchable
- HCore::UInt8 reset : 1; // Reset
- HCore::UInt8 BIST : 1; // BIST
- HCore::UInt8 clear : 1; // Clear busy upon R_OK
- HCore::UInt8 reserved0 : 1; // Reserved
- HCore::UInt8 pmp : 4; // Port multiplier port
+ NewOS::UInt8 reset : 1; // Reset
+ NewOS::UInt8 BIST : 1; // BIST
+ NewOS::UInt8 clear : 1; // Clear busy upon R_OK
+ NewOS::UInt8 reserved0 : 1; // Reserved
+ NewOS::UInt8 pmp : 4; // Port multiplier port
- HCore::UInt16 prdtl; // Physical region descriptor table length in entries
- volatile HCore::UInt32 prdbc; // Physical region descriptor byte count transferred
+ NewOS::UInt16 prdtl; // Physical region descriptor table length in entries
+ volatile NewOS::UInt32 prdbc; // Physical region descriptor byte count transferred
- HCore::UInt32 ctba; // Command table descriptor base address
- HCore::UInt32 ctbau; // Command table descriptor base address upper 32 bits
+ NewOS::UInt32 ctba; // Command table descriptor base address
+ NewOS::UInt32 ctbau; // Command table descriptor base address upper 32 bits
- HCore::UInt32 reserved1[4]; // Reserved
+ NewOS::UInt32 reserved1[4]; // Reserved
} HbaCmdHeader;
typedef struct HbaFis final {
// 0x00
FisDmaSetup dsfis; // DMA Setup FIS
- HCore::UInt8 pad0[4];
+ NewOS::UInt8 pad0[4];
// 0x20
FisPioSetup psfis; // PIO Setup FIS
- HCore::UInt8 pad1[12];
+ NewOS::UInt8 pad1[12];
// 0x40
FisRegD2H rfis; // Register – Device to Host FIS
- HCore::UInt8 pad2[4];
+ NewOS::UInt8 pad2[4];
// 0x58
FisDevBits sdbfis; // Set Device Bit FIS
// 0x60
- HCore::UInt8 ufis[64];
+ NewOS::UInt8 ufis[64];
// 0xA0
- HCore::UInt8 rsv[0x100 - 0xA0];
+ NewOS::UInt8 rsv[0x100 - 0xA0];
} HbaFis;
typedef struct HbaPrdtEntry final {
- HCore::UInt32 dba; // Data base address
- HCore::UInt32 dbau; // Data base address upper 32 bits
- HCore::UInt32 reserved0; // Reserved
+ NewOS::UInt32 dba; // Data base address
+ NewOS::UInt32 dbau; // Data base address upper 32 bits
+ NewOS::UInt32 reserved0; // Reserved
// DW3
- HCore::UInt32 dbc : 22; // Byte count, 4M max
- HCore::UInt32 reserved1 : 9; // Reserved
- HCore::UInt32 interruptBit : 1; // Interrupt on completion
+ NewOS::UInt32 dbc : 22; // Byte count, 4M max
+ NewOS::UInt32 reserved1 : 9; // Reserved
+ NewOS::UInt32 interruptBit : 1; // Interrupt on completion
} HbaPrdtEntry;
typedef struct HbaCmdTbl final {
- HCore::UInt8 cfis[64]; // Command FIS
- HCore::UInt8 acmd[16]; // ATAPI command, 12 or 16 bytes
- HCore::UInt8 rsv[48]; // Reserved
+ NewOS::UInt8 cfis[64]; // Command FIS
+ NewOS::UInt8 acmd[16]; // ATAPI command, 12 or 16 bytes
+ NewOS::UInt8 rsv[48]; // Reserved
struct HbaPrdtEntry prdtEntries[1]; // Physical region descriptor table entries, 0 ~ 65535
} HbaCmdTbl;
@@ -320,14 +320,14 @@ typedef struct HbaCmdTbl final {
/// @brief Initializes an AHCI disk.
/// @param PortsImplemented the amount of port that have been detected.
/// @return
-HCore::Boolean drv_ahci_init(HCore::UInt16& PortsImplemented);
+NewOS::Boolean drv_ahci_init(NewOS::UInt16& PortsImplemented);
-HCore::Boolean drv_ahci_detected(HCore::Void);
+NewOS::Boolean drv_ahci_detected(NewOS::Void);
-HCore::Void drv_ahci_read(HCore::UInt64 Lba, HCore::UInt16 IO, HCore::UInt8 Master, HCore::Char* Buf,
- HCore::SizeT SectorSz, HCore::SizeT Size);
+NewOS::Void drv_ahci_read(NewOS::UInt64 Lba, NewOS::UInt16 IO, NewOS::UInt8 Master, NewOS::Char* Buf,
+ NewOS::SizeT SectorSz, NewOS::SizeT Size);
-HCore::Void drv_ahci_write(HCore::UInt64 Lba, HCore::UInt16 IO, HCore::UInt8 Master, HCore::Char* Buf,
- HCore::SizeT SectorSz, HCore::SizeT Size);
+NewOS::Void drv_ahci_write(NewOS::UInt64 Lba, NewOS::UInt16 IO, NewOS::UInt8 Master, NewOS::Char* Buf,
+ NewOS::SizeT SectorSz, NewOS::SizeT Size);
#endif // ifdef __KERNEL__
diff --git a/Private/Builtins/ATA/Defines.hxx b/Private/Builtins/ATA/Defines.hxx
index fbb7c63c..0a07bc68 100644
--- a/Private/Builtins/ATA/Defines.hxx
+++ b/Private/Builtins/ATA/Defines.hxx
@@ -127,19 +127,19 @@ enum {
#ifdef __KERNEL__
-HCore::Boolean drv_ata_init(HCore::UInt16 Bus, HCore::UInt8 Drive, HCore::UInt16& OutBus,
- HCore::UInt8& OutMaster);
+NewOS::Boolean drv_ata_init(NewOS::UInt16 Bus, NewOS::UInt8 Drive, NewOS::UInt16& OutBus,
+ NewOS::UInt8& OutMaster);
-HCore::Boolean drv_ata_detected(HCore::Void);
+NewOS::Boolean drv_ata_detected(NewOS::Void);
-HCore::Void drv_ata_select(HCore::UInt16 Bus);
+NewOS::Void drv_ata_select(NewOS::UInt16 Bus);
-HCore::Boolean drv_ata_wait_io(HCore::UInt16 IO);
+NewOS::Boolean drv_ata_wait_io(NewOS::UInt16 IO);
-HCore::Void drv_ata_read(HCore::UInt64 Lba, HCore::UInt16 IO, HCore::UInt8 Master, HCore::Char* Buf,
- HCore::SizeT SectorSz, HCore::SizeT Size);
+NewOS::Void drv_ata_read(NewOS::UInt64 Lba, NewOS::UInt16 IO, NewOS::UInt8 Master, NewOS::Char* Buf,
+ NewOS::SizeT SectorSz, NewOS::SizeT Size);
-HCore::Void drv_ata_write(HCore::UInt64 Lba, HCore::UInt16 IO, HCore::UInt8 Master, HCore::Char* Buf,
- HCore::SizeT SectorSz, HCore::SizeT Size);
+NewOS::Void drv_ata_write(NewOS::UInt64 Lba, NewOS::UInt16 IO, NewOS::UInt8 Master, NewOS::Char* Buf,
+ NewOS::SizeT SectorSz, NewOS::SizeT Size);
#endif // ifdef __KERNEL__
diff --git a/Private/Builtins/PS2/PS2MouseInterface.hxx b/Private/Builtins/PS2/PS2MouseInterface.hxx
index 2be85af1..8ef47581 100644
--- a/Private/Builtins/PS2/PS2MouseInterface.hxx
+++ b/Private/Builtins/PS2/PS2MouseInterface.hxx
@@ -17,7 +17,7 @@
#include <CompilerKit/CompilerKit.hxx>
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
/// @brief PS/2 Mouse driver interface
class PS2MouseInterface final {
public:
@@ -98,4 +98,4 @@ class PS2MouseInterface final {
return HAL::In8(0x60);
}
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Builtins/README.TXT b/Private/Builtins/README.TXT
index 2e341e5d..4cb791f7 100644
--- a/Private/Builtins/README.TXT
+++ b/Private/Builtins/README.TXT
@@ -1,12 +1,12 @@
==============
-HCore Builtins
+NewOS Builtins
==============
===============
What are these?
===============
-These are HCore builtins device drivers.
+These are NewOS builtins device drivers.
===========
Maintainers
diff --git a/Private/Builtins/Toolbox/Toolbox.hxx b/Private/Builtins/Toolbox/Toolbox.hxx
index ebd8fc1e..f831acb5 100644
--- a/Private/Builtins/Toolbox/Toolbox.hxx
+++ b/Private/Builtins/Toolbox/Toolbox.hxx
@@ -8,11 +8,11 @@
#include <NewKit/Defines.hpp>
-EXTERN_C HCore::Void _hal_init_mouse();
-EXTERN_C HCore::Boolean _hal_draw_mouse();
-EXTERN_C HCore::Void _hal_handle_mouse();
-EXTERN_C HCore::Boolean _hal_left_button_pressed();
-EXTERN_C HCore::Boolean _hal_middle_button_pressed();
-EXTERN_C HCore::Boolean _hal_right_button_pressed();
+EXTERN_C NewOS::Void _hal_init_mouse();
+EXTERN_C NewOS::Boolean _hal_draw_mouse();
+EXTERN_C NewOS::Void _hal_handle_mouse();
+EXTERN_C NewOS::Boolean _hal_left_button_pressed();
+EXTERN_C NewOS::Boolean _hal_middle_button_pressed();
+EXTERN_C NewOS::Boolean _hal_right_button_pressed();
#include <Builtins/Toolbox/Utils.hxx>
diff --git a/Private/Builtins/Toolbox/Utils.hxx b/Private/Builtins/Toolbox/Utils.hxx
index 7dec8608..29ca585a 100644
--- a/Private/Builtins/Toolbox/Utils.hxx
+++ b/Private/Builtins/Toolbox/Utils.hxx
@@ -4,7 +4,7 @@
// Last Rev
// Sat Feb 24 CET 2024
-#define ToolboxInitRsrc() HCore::SizeT uA = 0
+#define ToolboxInitRsrc() NewOS::SizeT uA = 0
#define kClearClr RGB(00, 00, 00)
@@ -14,17 +14,17 @@
#define ToolboxDrawRsrc(ImgPtr, _Height, _Width, BaseX, BaseY) \
uA = 0; \
\
- for (HCore::SizeT i = BaseX; i < _Height + BaseX; ++i) { \
- for (HCore::SizeT u = BaseY; u < _Width + BaseY; ++u) { \
+ for (NewOS::SizeT i = BaseX; i < _Height + BaseX; ++i) { \
+ for (NewOS::SizeT u = BaseY; u < _Width + BaseY; ++u) { \
if (ImgPtr[uA] == 0) { \
- *(((volatile HCore::UInt32*)(kHandoverHeader->f_GOP.f_The + \
+ *(((volatile NewOS::UInt32*)(kHandoverHeader->f_GOP.f_The + \
4 * \
kHandoverHeader->f_GOP \
.f_PixelPerLine * \
i + \
4 * u))) |= ImgPtr[uA]; \
} else { \
- *(((volatile HCore::UInt32*)(kHandoverHeader->f_GOP.f_The + \
+ *(((volatile NewOS::UInt32*)(kHandoverHeader->f_GOP.f_The + \
4 * \
kHandoverHeader->f_GOP \
.f_PixelPerLine * \
@@ -40,9 +40,9 @@
/// @brief Cleans a resource.
#define ToolboxClearZone(_Height, _Width, BaseX, BaseY) \
\
- for (HCore::SizeT i = BaseX; i < _Height + BaseX; ++i) { \
- for (HCore::SizeT u = BaseY; u < _Width + BaseY; ++u) { \
- *(((volatile HCore::UInt32*)(kHandoverHeader->f_GOP.f_The + \
+ for (NewOS::SizeT i = BaseX; i < _Height + BaseX; ++i) { \
+ for (NewOS::SizeT u = BaseY; u < _Width + BaseY; ++u) { \
+ *(((volatile NewOS::UInt32*)(kHandoverHeader->f_GOP.f_The + \
4 * \
kHandoverHeader->f_GOP \
.f_PixelPerLine * \
@@ -55,9 +55,9 @@
/// @brief Draws inside a zone.
#define ToolboxDrawZone(_Clr, _Height, _Width, BaseX, BaseY) \
\
- for (HCore::SizeT i = BaseX; i < _Width + BaseX; ++i) { \
- for (HCore::SizeT u = BaseY; u < _Height + BaseY; ++u) { \
- *(((volatile HCore::UInt32*)(kHandoverHeader->f_GOP.f_The + \
+ for (NewOS::SizeT i = BaseX; i < _Width + BaseX; ++i) { \
+ for (NewOS::SizeT u = BaseY; u < _Height + BaseY; ++u) { \
+ *(((volatile NewOS::UInt32*)(kHandoverHeader->f_GOP.f_The + \
4 * \
kHandoverHeader->f_GOP \
.f_PixelPerLine * \
diff --git a/Private/Builtins/XHCI/Defines.hxx b/Private/Builtins/XHCI/Defines.hxx
index 32eb8cca..519d6635 100644
--- a/Private/Builtins/XHCI/Defines.hxx
+++ b/Private/Builtins/XHCI/Defines.hxx
@@ -16,7 +16,7 @@
#include <NewKit/Defines.hpp>
-using namespace HCore;
+using namespace NewOS;
#define kUSBCommand (UInt16)0x0
#define kUSBStatus (UInt16)0x2
diff --git a/Private/CFKit/GUIDWizard.hpp b/Private/CFKit/GUIDWizard.hpp
index 13cc668b..f7cc212e 100644
--- a/Private/CFKit/GUIDWizard.hpp
+++ b/Private/CFKit/GUIDWizard.hpp
@@ -15,7 +15,7 @@
#include <NewKit/Stream.hpp>
#include <NewKit/String.hpp>
-namespace HCore::XRN::Version1 {
+namespace NewOS::XRN::Version1 {
Ref<GUIDSequence*> make_sequence(const ArrayList<UShort>& seq);
-ErrorOr<Ref<HCore::StringView>> try_guid_to_string(Ref<GUIDSequence*>& guid);
-} // namespace HCore::XRN::Version1
+ErrorOr<Ref<NewOS::StringView>> try_guid_to_string(Ref<GUIDSequence*>& guid);
+} // namespace NewOS::XRN::Version1
diff --git a/Private/CFKit/GUIDWrapper.hpp b/Private/CFKit/GUIDWrapper.hpp
index c237985c..8a71c614 100644
--- a/Private/CFKit/GUIDWrapper.hpp
+++ b/Private/CFKit/GUIDWrapper.hpp
@@ -15,7 +15,7 @@
#define kXRNNil "@{........-....-M...-N...-............}"
// eXtensible Resource Information
-namespace HCore::XRN {
+namespace NewOS::XRN {
union GUIDSequence {
alignas(8) UShort u8[16];
alignas(8) UShort u16[8];
@@ -46,4 +46,4 @@ class GUID final {
private:
GUIDSequence m_UUID;
};
-} // namespace HCore::XRN
+} // namespace NewOS::XRN
diff --git a/Private/CFKit/IPCEndpoint.hxx b/Private/CFKit/IPCEndpoint.hxx
index 7f6f3f22..a6e8f90d 100644
--- a/Private/CFKit/IPCEndpoint.hxx
+++ b/Private/CFKit/IPCEndpoint.hxx
@@ -19,9 +19,9 @@
#define kRemoteInvalid "00.00.00.00:00000000"
#define kRemoteMaxLen 21
-namespace HCore {
+namespace NewOS {
typedef UIntPtr ipc_method_type;
typedef Char ipc_remote_type[kRemoteMaxLen];
-} // namespace HCore
+} // namespace NewOS
#endif // _INC_IPC_ENDPOINT_HXX_ \ No newline at end of file
diff --git a/Private/CFKit/Property.hpp b/Private/CFKit/Property.hpp
index e5d7fae0..84b4ed64 100644
--- a/Private/CFKit/Property.hpp
+++ b/Private/CFKit/Property.hpp
@@ -12,7 +12,7 @@
#include <NewKit/Function.hpp>
#include <NewKit/String.hpp>
-namespace HCore {
+namespace NewOS {
using PropertyId = Int;
class Property {
@@ -35,6 +35,6 @@ class Property {
template <SSizeT N>
using PropertyArray = Array<Property, N>;
-} // namespace HCore
+} // namespace NewOS
#endif // !_INC_PLIST_HPP__
diff --git a/Private/CFKit/URL.hpp b/Private/CFKit/URL.hpp
index eb8f674f..4131247c 100644
--- a/Private/CFKit/URL.hpp
+++ b/Private/CFKit/URL.hpp
@@ -10,7 +10,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/String.hpp>
-namespace HCore {
+namespace NewOS {
class Url final {
public:
explicit Url(StringView &strUrl);
@@ -26,7 +26,7 @@ class Url final {
ErrorOr<StringView> url_extract_location(const char *url);
ErrorOr<StringView> url_extract_protocol(const char *url);
-} // namespace HCore
+} // namespace NewOS
#endif /* ifndef _INC_URL_HPP_ */
diff --git a/Private/FSKit/HCFS.hxx b/Private/FSKit/HCFS.hxx
index 2d7e5627..6386a84d 100644
--- a/Private/FSKit/HCFS.hxx
+++ b/Private/FSKit/HCFS.hxx
@@ -9,7 +9,7 @@
#pragma once
/**
- @brief HCore File System.
+ @brief NewOS File System.
@author Amlal EL Mahrouss
*/
@@ -32,21 +32,21 @@
typedef struct HCFSBTree final {
/// @brief The Catalog Data record.
struct PACKED {
- HCore::Lba fDataCatalog;
- HCore::Lba fRsrcCatalog;
- HCore::SizeT fDataCatalogSize;
- HCore::SizeT fRsrcCatalogSize;
+ NewOS::Lba fDataCatalog;
+ NewOS::Lba fRsrcCatalog;
+ NewOS::SizeT fDataCatalogSize;
+ NewOS::SizeT fRsrcCatalogSize;
} fCatalogData;
- HCore::Lba fRelatedTrees[12];
- HCore::Char fReserved[384];
+ NewOS::Lba fRelatedTrees[12];
+ NewOS::Char fReserved[384];
} PACKED HCFSBTree;
/// @brief Catalog file for HCFS.
typedef struct HCFSCatalog {
- HCore::Char fCatalogName[kHCFSNameLen];
- HCore::UInt32 fCatalogKind;
- HCore::UInt32 fCatalogFlags;
+ NewOS::Char fCatalogName[kHCFSNameLen];
+ NewOS::UInt32 fCatalogKind;
+ NewOS::UInt32 fCatalogFlags;
/// @brief Tree information structure.
/// 0: BTree LBA.
@@ -54,9 +54,9 @@ typedef struct HCFSCatalog {
/// 3: Last BTree LBA.
/// 4: First BTree LBA.
/// Everything else is reserved.
- HCore::Lba fTreeInfo[12];
+ NewOS::Lba fTreeInfo[12];
- HCore::Char fReserved[152];
+ NewOS::Char fReserved[152];
} HCFSCatalog;
#define kHCFSCatalogKindFile 1
@@ -74,21 +74,21 @@ enum {
/// @brief This is a boot block, used by HCFS to boot the system (if formated using this filesystem.)
typedef struct HCFSBootBlock final {
- HCore::Char Ident[kHCFSIdentLen];
- HCore::Char Shell[kHCFSNameLen];
+ NewOS::Char Ident[kHCFSIdentLen];
+ NewOS::Char Shell[kHCFSNameLen];
- HCore::Int64 NumParts; // number of sub-partitions.
- HCore::Int64 FreeSectors;
- HCore::Int64 SectorCount;
- HCore::Int64 SectorSz;
+ NewOS::Int64 NumParts; // number of sub-partitions.
+ NewOS::Int64 FreeSectors;
+ NewOS::Int64 SectorCount;
+ NewOS::Int64 SectorSz;
- HCore::Int64 DiskSize; // size of media.
- HCore::Int32 DiskKind; // kind of disk.
+ NewOS::Int64 DiskSize; // size of media.
+ NewOS::Int32 DiskKind; // kind of disk.
- HCore::Lba FirstPartBlock;
- HCore::Lba LastPartBlock;
+ NewOS::Lba FirstPartBlock;
+ NewOS::Lba LastPartBlock;
- HCore::Char Pad[kHCFSPadLen];
+ NewOS::Char Pad[kHCFSPadLen];
} PACKED HCFSBootBlock;
// EOF.
diff --git a/Private/FSKit/IndexableProperty.hxx b/Private/FSKit/IndexableProperty.hxx
index 86bacfdf..ab034bc6 100644
--- a/Private/FSKit/IndexableProperty.hxx
+++ b/Private/FSKit/IndexableProperty.hxx
@@ -10,7 +10,7 @@
#include <CompilerKit/CompilerKit.hxx>
#include <KernelKit/DriveManager.hxx>
-namespace HCore {
+namespace NewOS {
namespace Indexer {
struct IndexProperty final {
public:
@@ -40,4 +40,4 @@ class IndexableProperty final : public Property {
UInt32 fFlags;
};
} // namespace Indexer
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/FSKit/NewFS.hxx b/Private/FSKit/NewFS.hxx
index 70ea0881..43596d62 100644
--- a/Private/FSKit/NewFS.hxx
+++ b/Private/FSKit/NewFS.hxx
@@ -74,7 +74,7 @@
#define kNewFSEOF (-1)
#define kNewFSBitWidth (sizeof(NewCharType))
-#define kNewFSLbaType (HCore::Lba)
+#define kNewFSLbaType (NewOS::Lba)
/// Start After the PM headers, pad 1024 bytes.
#define kNewFSAddressAsLba (1024U)
@@ -90,7 +90,7 @@
#define kNewFSFlagUnallocated 0x0F
#define kNewFSFlagCatalog 0xFF
-typedef HCore::Char NewCharType;
+typedef NewOS::Char NewCharType;
enum {
kNewFSHardDrive = 0xC0, // Hard Drive (SSD, HDD)
@@ -105,32 +105,32 @@ enum {
struct PACKED NewCatalog final {
NewCharType Name[kNewFSNodeNameLen];
- HCore::Int32 Flags;
- HCore::Int32 Kind;
+ NewOS::Int32 Flags;
+ NewOS::Int32 Kind;
- HCore::Lba FirstFork;
- HCore::Lba LastFork;
+ NewOS::Lba FirstFork;
+ NewOS::Lba LastFork;
- HCore::Lba NextSibling;
- HCore::Lba PrevSibling;
+ NewOS::Lba NextSibling;
+ NewOS::Lba PrevSibling;
};
/// @brief Fork type.
struct PACKED NewFork final {
NewCharType Name[kNewFSNodeNameLen];
- HCore::Int32 Flags;
- HCore::Int32 Kind;
+ NewOS::Int32 Flags;
+ NewOS::Int32 Kind;
- HCore::Int64 ResourceId;
- HCore::Int32 ResourceKind;
- HCore::Int32 ResourceFlags;
+ NewOS::Int64 ResourceId;
+ NewOS::Int32 ResourceKind;
+ NewOS::Int32 ResourceFlags;
- HCore::Lba DataOffset; //8 Where to look for this data?
- HCore::SizeT DataSize; /// Data size according using sector count.
+ NewOS::Lba DataOffset; //8 Where to look for this data?
+ NewOS::SizeT DataSize; /// Data size according using sector count.
- HCore::Lba NextSibling;
- HCore::Lba PreviousSibling;
+ NewOS::Lba NextSibling;
+ NewOS::Lba PreviousSibling;
};
/// @brief Partition block type
@@ -138,24 +138,24 @@ struct PACKED NewPartitionBlock final {
NewCharType Ident[kNewFSIdentLen];
NewCharType PartitionName[kPartLen];
- HCore::Int32 Flags;
- HCore::Int32 Kind;
+ NewOS::Int32 Flags;
+ NewOS::Int32 Kind;
- HCore::Lba StartCatalog;
- HCore::SizeT CatalogCount;
+ NewOS::Lba StartCatalog;
+ NewOS::SizeT CatalogCount;
- HCore::SizeT DiskSize;
+ NewOS::SizeT DiskSize;
- HCore::SizeT FreeCatalog;
- HCore::SizeT FreeSectors;
+ NewOS::SizeT FreeCatalog;
+ NewOS::SizeT FreeSectors;
- HCore::SizeT SectorCount;
- HCore::SizeT SectorSize;
+ NewOS::SizeT SectorCount;
+ NewOS::SizeT SectorSize;
- HCore::Char Pad[kNewFSPadLen];
+ NewOS::Char Pad[kNewFSPadLen];
};
-namespace HCore {
+namespace NewOS {
///
/// \name NewFSParser
/// \brief NewFS parser class. (catalog creation, remove removal, root, forks...)
@@ -213,7 +213,7 @@ class NewFilesystemHelper final {
static const char* UpDir();
static const char Separator();
};
-} // namespace HCore
+} // namespace NewOS
enum {
kNewFSPartGPT,
diff --git a/Private/FSKit/NewFSIteratorInterface.hxx b/Private/FSKit/NewFSIteratorInterface.hxx
index 0c7a6743..7e1d8652 100644
--- a/Private/FSKit/NewFSIteratorInterface.hxx
+++ b/Private/FSKit/NewFSIteratorInterface.hxx
@@ -9,7 +9,7 @@
#include <FSKit/IndexableProperty.hxx>
#include <NewKit/MutableArray.hpp>
-namespace HCore {
+namespace NewOS {
namespace Indexer {
class NewFSIteratorInterface;
@@ -48,4 +48,4 @@ class NewFSIteratorInterface {
MutableArray<IndexableProperty> fProps;
};
} // namespace Indexer
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/FirmwareKit/EFI/API.hxx b/Private/FirmwareKit/EFI/API.hxx
index e025e7e0..4431facb 100644
--- a/Private/FirmwareKit/EFI/API.hxx
+++ b/Private/FirmwareKit/EFI/API.hxx
@@ -86,6 +86,6 @@ inline void InitEFI(EfiSystemTable *SystemTable) noexcept {
#endif // ifdef __BOOTLOADER__
-#define kHCoreSubsystem 17
+#define kNewOSSubsystem 17
#endif /* ifndef __EFI_API__ */
diff --git a/Private/FirmwareKit/EFI/EFI.hxx b/Private/FirmwareKit/EFI/EFI.hxx
index 7ac8d624..1d56f757 100644
--- a/Private/FirmwareKit/EFI/EFI.hxx
+++ b/Private/FirmwareKit/EFI/EFI.hxx
@@ -8,7 +8,7 @@
#define __EFI__
/**
-@brief HCore Implementation of EFI.
+@brief NewOS Implementation of EFI.
@note This API is in WiP, so it's not 'pretty', just deal with it. We'll be
improving that later.
@author Amlal El Mahrouss
@@ -16,7 +16,7 @@ improving that later.
#include <NewKit/Defines.hpp>
-using namespace HCore;
+using namespace NewOS;
/* we always use stdcall in EFI, the pascal way of calling functions. */
diff --git a/Private/FirmwareKit/EPM.hxx b/Private/FirmwareKit/EPM.hxx
index 4c8d48f2..5657fb06 100644
--- a/Private/FirmwareKit/EPM.hxx
+++ b/Private/FirmwareKit/EPM.hxx
@@ -21,23 +21,23 @@
/// @brief EPM GUID block.
typedef struct BlockGUID {
- HCore::UInt32 Data1;
- HCore::UInt16 Data2;
- HCore::UInt16 Data3;
- HCore::UInt8 Data4[8];
+ NewOS::UInt32 Data1;
+ NewOS::UInt16 Data2;
+ NewOS::UInt16 Data3;
+ NewOS::UInt8 Data4[8];
} BlockGUID;
/**
* @brief The EPM bootloader block.
*/
struct PACKED BootBlock {
- HCore::Char Magic[kEPMMagicLength];
- HCore::Char Name[kEPMNameLength];
+ NewOS::Char Magic[kEPMMagicLength];
+ NewOS::Char Name[kEPMNameLength];
BlockGUID Uuid;
- HCore::Int32 Version;
- HCore::Int64 NumBlocks;
- HCore::Int64 SectorSz;
- HCore::Int64 SectorStart;
+ NewOS::Int32 Version;
+ NewOS::Int64 NumBlocks;
+ NewOS::Int64 SectorSz;
+ NewOS::Int64 SectorStart;
};
/**
@@ -45,14 +45,14 @@ struct PACKED BootBlock {
* used to describe a partition inside a media.
*/
struct PACKED PartitionBlock {
- HCore::Char Name[kEPMNameLength];
- HCore::Int32 Magic;
- HCore::Int64 SectorEnd;
- HCore::Int64 SectorSz;
- HCore::Int64 SectorStart;
- HCore::Int16 Kind;
- HCore::Int32 Version;
- HCore::Char Fs[kEPMFilesystemLength]; /* NewFS, HCFS... */
+ NewOS::Char Name[kEPMNameLength];
+ NewOS::Int32 Magic;
+ NewOS::Int64 SectorEnd;
+ NewOS::Int64 SectorSz;
+ NewOS::Int64 SectorStart;
+ NewOS::Int16 Kind;
+ NewOS::Int32 Version;
+ NewOS::Char Fs[kEPMFilesystemLength]; /* NewFS, HCFS... */
};
/* @brief AMD64 magic for EPM */
@@ -84,7 +84,7 @@ enum kEPMKind {
kEPMMpUx = 0xcf,
kEPMLinux = 0x8f,
kEPMBSD = 0x9f,
- kEPMHCore = 0x1f,
+ kEPMNewOS = 0x1f,
};
typedef struct BootBlock BootBlockType;
diff --git a/Private/FirmwareKit/Handover.hxx b/Private/FirmwareKit/Handover.hxx
index 46a860ec..ae64f223 100644
--- a/Private/FirmwareKit/Handover.hxx
+++ b/Private/FirmwareKit/Handover.hxx
@@ -26,7 +26,7 @@
#define kHandoverStructSz sizeof(HEL::HandoverHeader)
-namespace HCore::HEL {
+namespace NewOS::HEL {
/**
@brief the kind of executable we're loading.
*/
@@ -85,4 +85,4 @@ struct HandoverInformationHeader {
@brief Handover Jump Proc
*/
typedef void (*HandoverProc)(HandoverInformationHeader* pHandover);
-} // namespace HCore::HEL
+} // namespace NewOS::HEL
diff --git a/Private/HALKit/AMD64/HalACPIFactoryInterface.cxx b/Private/HALKit/AMD64/HalACPIFactoryInterface.cxx
index 204274b9..83642206 100644
--- a/Private/HALKit/AMD64/HalACPIFactoryInterface.cxx
+++ b/Private/HALKit/AMD64/HalACPIFactoryInterface.cxx
@@ -8,7 +8,7 @@
#include <HALKit/AMD64/Processor.hpp>
#include <NewKit/String.hpp>
-namespace HCore {
+namespace NewOS {
ACPIFactoryInterface::ACPIFactoryInterface(voidPtr rsdPtr) : m_Rsdp(rsdPtr), m_Entries(0) {
volatile RSDP *_rsdPtr = reinterpret_cast<volatile RSDP *>(this->m_Rsdp);
@@ -73,4 +73,4 @@ void rt_shutdown_acpi_qemu_30_plus(void) { HAL::Out16(0x604, 0x2000); }
void rt_shutdown_acpi_virtualbox(void) { HAL::Out16(0x4004, 0x3400); }
/// You have to parse the MADT!
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/AMD64/HalCoreInterruptHandlerAMD64.cpp b/Private/HALKit/AMD64/HalCoreInterruptHandlerAMD64.cpp
index c55b9857..9ac3f3e1 100644
--- a/Private/HALKit/AMD64/HalCoreInterruptHandlerAMD64.cpp
+++ b/Private/HALKit/AMD64/HalCoreInterruptHandlerAMD64.cpp
@@ -8,65 +8,65 @@
#include <KernelKit/ProcessScheduler.hpp>
#include <NewKit/String.hpp>
-EXTERN_C void idt_handle_gpf(HCore::UIntPtr rsp) {
- MUST_PASS(HCore::ProcessScheduler::Shared().Leak().GetCurrent());
+EXTERN_C void idt_handle_gpf(NewOS::UIntPtr rsp) {
+ MUST_PASS(NewOS::ProcessScheduler::Shared().Leak().GetCurrent());
- HCore::kcout << "NewKernel.exe: Stack Pointer: "
- << HCore::StringBuilder::FromInt("rsp{%}", rsp);
+ NewOS::kcout << "NewKernel.exe: Stack Pointer: "
+ << NewOS::StringBuilder::FromInt("rsp{%}", rsp);
- HCore::kcout
+ NewOS::kcout
<< "NewKernel.exe: General Protection Fault, caused by "
- << HCore::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName();
+ << NewOS::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName();
- HCore::ProcessScheduler::Shared().Leak().GetCurrent().Leak().Crash();
+ NewOS::ProcessScheduler::Shared().Leak().GetCurrent().Leak().Crash();
}
-EXTERN_C void idt_handle_scheduler(HCore::UIntPtr rsp) {
- HCore::kcout << HCore::StringBuilder::FromInt("rsp{%}", rsp);
+EXTERN_C void idt_handle_scheduler(NewOS::UIntPtr rsp) {
+ NewOS::kcout << NewOS::StringBuilder::FromInt("rsp{%}", rsp);
- HCore::kcout
+ NewOS::kcout
<< "NewKernel.exe: Will be scheduled back later "
- << HCore::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName()
- << HCore::end_line();
+ << NewOS::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName()
+ << NewOS::end_line();
/// schedule another process.
- if (!HCore::ProcessHelper::StartScheduling()) {
- HCore::kcout << "NewKernel.exe: Continue schedule this process...\r\n";
+ if (!NewOS::ProcessHelper::StartScheduling()) {
+ NewOS::kcout << "NewKernel.exe: Continue schedule this process...\r\n";
}
}
-EXTERN_C void idt_handle_pf(HCore::UIntPtr rsp) {
- HCore::kcout << HCore::StringBuilder::FromInt("rsp{%}", rsp);
+EXTERN_C void idt_handle_pf(NewOS::UIntPtr rsp) {
+ NewOS::kcout << NewOS::StringBuilder::FromInt("rsp{%}", rsp);
- MUST_PASS(HCore::ProcessScheduler::Shared().Leak().GetCurrent());
+ MUST_PASS(NewOS::ProcessScheduler::Shared().Leak().GetCurrent());
- HCore::kcout
+ NewOS::kcout
<< "NewKernel.exe: Segmentation Fault, caused by "
- << HCore::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName();
+ << NewOS::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName();
- HCore::ProcessScheduler::Shared().Leak().GetCurrent().Leak().Crash();
+ NewOS::ProcessScheduler::Shared().Leak().GetCurrent().Leak().Crash();
}
-EXTERN_C void idt_handle_math(HCore::UIntPtr rsp) {
- HCore::kcout << HCore::StringBuilder::FromInt("rsp{%}", rsp);
+EXTERN_C void idt_handle_math(NewOS::UIntPtr rsp) {
+ NewOS::kcout << NewOS::StringBuilder::FromInt("rsp{%}", rsp);
- MUST_PASS(HCore::ProcessScheduler::Shared().Leak().GetCurrent());
+ MUST_PASS(NewOS::ProcessScheduler::Shared().Leak().GetCurrent());
- HCore::kcout
+ NewOS::kcout
<< "NewKernel.exe: Math error, caused by "
- << HCore::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName();
+ << NewOS::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName();
- HCore::ProcessScheduler::Shared().Leak().GetCurrent().Leak().Crash();
+ NewOS::ProcessScheduler::Shared().Leak().GetCurrent().Leak().Crash();
}
-EXTERN_C void idt_handle_generic(HCore::UIntPtr rsp) {
- HCore::kcout << HCore::StringBuilder::FromInt("sp{%}", rsp);
+EXTERN_C void idt_handle_generic(NewOS::UIntPtr rsp) {
+ NewOS::kcout << NewOS::StringBuilder::FromInt("sp{%}", rsp);
- MUST_PASS(HCore::ProcessScheduler::Shared().Leak().GetCurrent());
+ MUST_PASS(NewOS::ProcessScheduler::Shared().Leak().GetCurrent());
- HCore::kcout
+ NewOS::kcout
<< "NewKernel.exe: Execution error, caused by "
- << HCore::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName();
+ << NewOS::ProcessScheduler::Shared().Leak().GetCurrent().Leak().GetName();
- HCore::ProcessScheduler::Shared().Leak().GetCurrent().Leak().Crash();
+ NewOS::ProcessScheduler::Shared().Leak().GetCurrent().Leak().Crash();
}
diff --git a/Private/HALKit/AMD64/HalCoreMultiProcessingAMD64.cpp b/Private/HALKit/AMD64/HalCoreMultiProcessingAMD64.cpp
index fe38189e..bbd3c6ea 100644
--- a/Private/HALKit/AMD64/HalCoreMultiProcessingAMD64.cpp
+++ b/Private/HALKit/AMD64/HalCoreMultiProcessingAMD64.cpp
@@ -13,7 +13,7 @@
///////////////////////////////////////////////////////////////////////////////////////
-namespace HCore::HAL {
+namespace NewOS::HAL {
constexpr Int32 kThreadAPIC = 0;
constexpr Int32 kThreadLAPIC = 1;
constexpr Int32 kThreadIOAPIC = 2;
@@ -122,6 +122,6 @@ void hal_system_get_cores(voidPtr rsdPtr) {
++counter;
}
}
-} // namespace HCore::HAL
+} // namespace NewOS::HAL
///////////////////////////////////////////////////////////////////////////////////////
diff --git a/Private/HALKit/AMD64/HalDebugOutput.cxx b/Private/HALKit/AMD64/HalDebugOutput.cxx
index 7eeae914..da40f5af 100644
--- a/Private/HALKit/AMD64/HalDebugOutput.cxx
+++ b/Private/HALKit/AMD64/HalDebugOutput.cxx
@@ -9,7 +9,7 @@
#include <KernelKit/Framebuffer.hpp>
#include <NewKit/Utils.hpp>
-namespace HCore {
+namespace NewOS {
enum CommStatus {
kStateInvalid,
kStateReady = 0xCF,
@@ -113,9 +113,9 @@ EXTERN_C void ke_io_read(const char* bytes) {
}
TerminalDevice TerminalDevice::Shared() noexcept {
- TerminalDevice out(HCore::ke_io_write, HCore::ke_io_read);
+ TerminalDevice out(NewOS::ke_io_write, NewOS::ke_io_read);
return out;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/AMD64/HalDebugPort.cxx b/Private/HALKit/AMD64/HalDebugPort.cxx
index df3fc6e9..996ef4e9 100644
--- a/Private/HALKit/AMD64/HalDebugPort.cxx
+++ b/Private/HALKit/AMD64/HalDebugPort.cxx
@@ -12,7 +12,7 @@
// after that we have start of additional data.
-namespace HCore {
+namespace NewOS {
void rt_debug_listen(DebuggerPortHeader* theHook) noexcept {
if (theHook == nullptr) return;
@@ -32,4 +32,4 @@ void rt_debug_listen(DebuggerPortHeader* theHook) noexcept {
if (HAL::In16(theHook->fPort[i] != kDebugUnboundPort)) theHook->fBoundCnt++;
}
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/AMD64/HalDescriptorLoader.cpp b/Private/HALKit/AMD64/HalDescriptorLoader.cpp
index df6caf7a..53bcd621 100644
--- a/Private/HALKit/AMD64/HalDescriptorLoader.cpp
+++ b/Private/HALKit/AMD64/HalDescriptorLoader.cpp
@@ -6,12 +6,12 @@
#include <ArchKit/ArchKit.hpp>
-namespace HCore::HAL {
+namespace NewOS::HAL {
namespace Detail {
STATIC RegisterGDT kRegGdt;
STATIC HAL::Register64 kRegIdt;
-STATIC ::HCore::Detail::AMD64::InterruptDescriptorAMD64
+STATIC ::NewOS::Detail::AMD64::InterruptDescriptorAMD64
kInterruptVectorTable[kKernelIdtSize];
STATIC Void RemapPIC(Void) noexcept {
@@ -46,7 +46,7 @@ Void GDTLoader::Load(RegisterGDT &gdt) {
}
Void IDTLoader::Load(Register64 &idt) {
- volatile ::HCore::UIntPtr **baseIdt = (volatile ::HCore::UIntPtr **)idt.Base;
+ volatile ::NewOS::UIntPtr **baseIdt = (volatile ::NewOS::UIntPtr **)idt.Base;
MUST_PASS(baseIdt);
@@ -66,7 +66,7 @@ Void IDTLoader::Load(Register64 &idt) {
}
Detail::kRegIdt.Base = reinterpret_cast<UIntPtr>(Detail::kInterruptVectorTable);
- Detail::kRegIdt.Limit = sizeof(::HCore::Detail::AMD64::InterruptDescriptorAMD64) *
+ Detail::kRegIdt.Limit = sizeof(::NewOS::Detail::AMD64::InterruptDescriptorAMD64) *
(kKernelIdtSize - 1);
hal_load_idt(Detail::kRegIdt);
@@ -75,4 +75,4 @@ Void IDTLoader::Load(Register64 &idt) {
void GDTLoader::Load(Ref<RegisterGDT> &gdt) { GDTLoader::Load(gdt.Leak()); }
void IDTLoader::Load(Ref<Register64> &idt) { IDTLoader::Load(idt.Leak()); }
-} // namespace HCore::HAL
+} // namespace NewOS::HAL
diff --git a/Private/HALKit/AMD64/HalHardwareAPIC.cpp b/Private/HALKit/AMD64/HalHardwareAPIC.cpp
index d2b99ed3..0c65ed5d 100644
--- a/Private/HALKit/AMD64/HalHardwareAPIC.cpp
+++ b/Private/HALKit/AMD64/HalHardwareAPIC.cpp
@@ -8,7 +8,7 @@
// bugs = 0
-namespace HCore {
+namespace NewOS {
// @brief wakes up thread.
// wakes up thread from hang.
void rt_wakeup_thread(HAL::StackFrame* stack) {
@@ -34,4 +34,4 @@ void rt_hang_thread(HAL::StackFrame* stack) {
HAL::rt_sti();
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/AMD64/HalInstallTIB.asm b/Private/HALKit/AMD64/HalInstallTIB.asm
index 2346b19c..ae3ead27 100644
--- a/Private/HALKit/AMD64/HalInstallTIB.asm
+++ b/Private/HALKit/AMD64/HalInstallTIB.asm
@@ -1,7 +1,7 @@
;; /*
;; * ========================================================
;; *
-;; * HCore
+;; * NewOS
;; * Copyright Mahrouss Logic, all rights reserved.
;; *
;; * ========================================================
diff --git a/Private/HALKit/AMD64/HalKernelMain.cxx b/Private/HALKit/AMD64/HalKernelMain.cxx
index 29cbdff2..029bca3c 100644
--- a/Private/HALKit/AMD64/HalKernelMain.cxx
+++ b/Private/HALKit/AMD64/HalKernelMain.cxx
@@ -16,23 +16,23 @@
#include <KernelKit/UserHeap.hpp>
#include <NewKit/Json.hpp>
-EXTERN_C HCore::VoidPtr kInterruptVectorTable[];
+EXTERN_C NewOS::VoidPtr kInterruptVectorTable[];
EXTERN_C void RuntimeMain();
EXTERN_C void hal_init_platform(
- HCore::HEL::HandoverInformationHeader* HandoverHeader) {
+ NewOS::HEL::HandoverInformationHeader* HandoverHeader) {
kHandoverHeader = HandoverHeader;
/// Setup kernel globals.
kKernelVirtualSize = HandoverHeader->f_VirtualSize;
- kKernelVirtualStart = reinterpret_cast<HCore::VoidPtr>(
- reinterpret_cast<HCore::UIntPtr>(HandoverHeader->f_VirtualStart) +
+ kKernelVirtualStart = reinterpret_cast<NewOS::VoidPtr>(
+ reinterpret_cast<NewOS::UIntPtr>(HandoverHeader->f_VirtualStart) +
kVirtualAddressStartOffset);
kKernelPhysicalSize = HandoverHeader->f_PhysicalSize;
kKernelPhysicalStart = HandoverHeader->f_PhysicalStart;
- STATIC HCore::HAL::Detail::HCoreGDT GDT = {
+ STATIC NewOS::HAL::Detail::NewOSGDT GDT = {
{0, 0, 0, 0x00, 0x00, 0}, // null entry
{0, 0, 0, 0x9a, 0xaf, 0}, // kernel code
{0, 0, 0, 0x92, 0xaf, 0}, // kernel data
@@ -41,28 +41,28 @@ EXTERN_C void hal_init_platform(
{0, 0, 0, 0x92, 0xaf, 0}, // user data
};
- HCore::HAL::RegisterGDT gdtBase;
+ NewOS::HAL::RegisterGDT gdtBase;
- gdtBase.Base = reinterpret_cast<HCore::UIntPtr>(&GDT);
- gdtBase.Limit = sizeof(HCore::HAL::Detail::HCoreGDT) - 1;
+ gdtBase.Base = reinterpret_cast<NewOS::UIntPtr>(&GDT);
+ gdtBase.Limit = sizeof(NewOS::HAL::Detail::NewOSGDT) - 1;
/// Load GDT.
- HCore::HAL::GDTLoader gdt;
+ NewOS::HAL::GDTLoader gdt;
gdt.Load(gdtBase);
/// Load IDT.
- HCore::HAL::Register64 idtBase;
- idtBase.Base = (HCore::UIntPtr)kInterruptVectorTable;
+ NewOS::HAL::Register64 idtBase;
+ idtBase.Base = (NewOS::UIntPtr)kInterruptVectorTable;
idtBase.Limit = 0;
- HCore::HAL::IDTLoader idt;
+ NewOS::HAL::IDTLoader idt;
idt.Load(idtBase);
/// START POST
- HCore::HAL::Detail::_ke_power_on_self_test();
+ NewOS::HAL::Detail::_ke_power_on_self_test();
/// END POST
@@ -77,5 +77,5 @@ EXTERN_C void hal_init_platform(
RuntimeMain();
- HCore::ke_stop(RUNTIME_CHECK_BOOTSTRAP);
+ NewOS::ke_stop(RUNTIME_CHECK_BOOTSTRAP);
}
diff --git a/Private/HALKit/AMD64/HalKernelMouse.cxx b/Private/HALKit/AMD64/HalKernelMouse.cxx
index 0cbf47dc..468a595f 100644
--- a/Private/HALKit/AMD64/HalKernelMouse.cxx
+++ b/Private/HALKit/AMD64/HalKernelMouse.cxx
@@ -10,17 +10,17 @@
#include <NewKit/Defines.hpp>
// forward decl.
-EXTERN_C HCore::Boolean _hal_draw_mouse();
-EXTERN_C HCore::Void _hal_init_mouse();
-
-STATIC HCore::Int32 kPrevX = 10;
-STATIC HCore::Int32 kPrevY = 10;
-STATIC HCore::Int32 kX = 10;
-STATIC HCore::Int32 kY = 10;
-STATIC HCore::Int32 kMouseCycle = 0;
-STATIC HCore::PS2MouseInterface kMousePS2;
-STATIC HCore::Char kMousePacket[4] = {};
-STATIC HCore::Boolean kMousePacketReady = false;
+EXTERN_C NewOS::Boolean _hal_draw_mouse();
+EXTERN_C NewOS::Void _hal_init_mouse();
+
+STATIC NewOS::Int32 kPrevX = 10;
+STATIC NewOS::Int32 kPrevY = 10;
+STATIC NewOS::Int32 kX = 10;
+STATIC NewOS::Int32 kY = 10;
+STATIC NewOS::Int32 kMouseCycle = 0;
+STATIC NewOS::PS2MouseInterface kMousePS2;
+STATIC NewOS::Char kMousePacket[4] = {};
+STATIC NewOS::Boolean kMousePacketReady = false;
#define kPS2Leftbutton 0b00000001
#define kPS2Middlebutton 0b00000010
@@ -30,10 +30,10 @@ STATIC HCore::Boolean kMousePacketReady = false;
#define kPS2XOverflow 0b01000000
#define kPS2YOverflow 0b10000000
-using namespace HCore;
+using namespace NewOS;
Void hal_handle_mouse() {
- HCore::UInt8 data = HAL::In8(0x60);
+ NewOS::UInt8 data = HAL::In8(0x60);
switch (kMouseCycle) {
case 0:
@@ -57,8 +57,8 @@ Void hal_handle_mouse() {
// Notify PIC controller that we're done with it's interrupt.
- HCore::HAL::Out8(0x20, 0x20);
- HCore::HAL::Out8(0xA0, 0x20);
+ NewOS::HAL::Out8(0x20, 0x20);
+ NewOS::HAL::Out8(0xA0, 0x20);
}
/// @brief Interrupt handler for the mouse.
diff --git a/Private/HALKit/AMD64/HalNewBoot.asm b/Private/HALKit/AMD64/HalNewBoot.asm
index 54d05f2f..995a848c 100644
--- a/Private/HALKit/AMD64/HalNewBoot.asm
+++ b/Private/HALKit/AMD64/HalNewBoot.asm
@@ -1,7 +1,7 @@
;; /*
;; * ========================================================
;; *
-;; * HCore
+;; * NewOS
;; * Copyright Mahrouss Logic, all rights reserved.
;; *
;; * ========================================================
diff --git a/Private/HALKit/AMD64/HalPageAlloc.cpp b/Private/HALKit/AMD64/HalPageAlloc.cpp
index 5f6564c0..53680668 100644
--- a/Private/HALKit/AMD64/HalPageAlloc.cpp
+++ b/Private/HALKit/AMD64/HalPageAlloc.cpp
@@ -9,8 +9,8 @@
#include <NewKit/Defines.hpp>
#include <NewKit/KernelCheck.hpp>
-STATIC HCore::Boolean kAllocationInProgress = false;
-namespace HCore {
+STATIC NewOS::Boolean kAllocationInProgress = false;
+namespace NewOS {
namespace HAL {
/// @brief Allocates a new page of memory.
/// @param sz the size of it.
@@ -46,4 +46,4 @@ auto hal_alloc_page(Boolean rw, Boolean user) -> VoidPtr {
return hal_try_alloc_new_page(rw, user);
}
} // namespace HAL
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/AMD64/HalPageAlloc.hpp b/Private/HALKit/AMD64/HalPageAlloc.hpp
index 5fe55992..9cd10213 100644
--- a/Private/HALKit/AMD64/HalPageAlloc.hpp
+++ b/Private/HALKit/AMD64/HalPageAlloc.hpp
@@ -26,15 +26,15 @@
#define kPTESize (0x1000)
#endif // !kPTESize
-EXTERN_C void hal_flush_tlb(HCore::UIntPtr pde);
-EXTERN_C void hal_write_cr3(HCore::UIntPtr pde);
-EXTERN_C void hal_write_cr0(HCore::UIntPtr bit);
+EXTERN_C void hal_flush_tlb(NewOS::UIntPtr pde);
+EXTERN_C void hal_write_cr3(NewOS::UIntPtr pde);
+EXTERN_C void hal_write_cr0(NewOS::UIntPtr bit);
-EXTERN_C HCore::UIntPtr hal_read_cr0(); // @brief CPU control register.
-EXTERN_C HCore::UIntPtr hal_read_cr2(); // @brief Fault address.
-EXTERN_C HCore::UIntPtr hal_read_cr3(); // @brief Page table.
+EXTERN_C NewOS::UIntPtr hal_read_cr0(); // @brief CPU control register.
+EXTERN_C NewOS::UIntPtr hal_read_cr2(); // @brief Fault address.
+EXTERN_C NewOS::UIntPtr hal_read_cr3(); // @brief Page table.
-namespace HCore::HAL {
+namespace NewOS::HAL {
struct PACKED PageTable64 final {
bool Present : 1;
bool Rw : 1;
@@ -42,9 +42,9 @@ struct PACKED PageTable64 final {
bool Wt : 1;
bool Cache : 1;
bool Accessed : 1;
- HCore::Int32 Reserved : 6;
- HCore::UIntPtr PhysicalAddress : 36;
- HCore::Int32 Reserved1 : 15;
+ NewOS::Int32 Reserved : 6;
+ NewOS::UIntPtr PhysicalAddress : 36;
+ NewOS::Int32 Reserved1 : 15;
bool ExecDisable : 1;
};
@@ -73,9 +73,9 @@ struct PageDirectory64 final {
};
VoidPtr hal_alloc_page(Boolean rw, Boolean user);
-} // namespace HCore::HAL
+} // namespace NewOS::HAL
-namespace HCore {
+namespace NewOS {
typedef HAL::PageTable64 PTE;
typedef HAL::PageDirectory64 PDE;
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/AMD64/HalProcessor.cpp b/Private/HALKit/AMD64/HalProcessor.cpp
index 9596a82b..4fea4e7e 100644
--- a/Private/HALKit/AMD64/HalProcessor.cpp
+++ b/Private/HALKit/AMD64/HalProcessor.cpp
@@ -11,7 +11,7 @@
* @brief This file is about processor specific functions (in/out...)
*/
-namespace HCore::HAL {
+namespace NewOS::HAL {
void Out8(UInt16 port, UInt8 value) {
asm volatile("outb %%al, %1" : : "a"(value), "Nd"(port) : "memory");
}
@@ -54,4 +54,4 @@ void rt_sti() { asm volatile("sti"); }
void rt_cld() { asm volatile("cld"); }
void rt_std() { asm volatile("std"); }
-} // namespace HCore::HAL
+} // namespace NewOS::HAL
diff --git a/Private/HALKit/AMD64/HalSMPCore.cxx b/Private/HALKit/AMD64/HalSMPCore.cxx
index 3be9c0c7..a48806e1 100644
--- a/Private/HALKit/AMD64/HalSMPCore.cxx
+++ b/Private/HALKit/AMD64/HalSMPCore.cxx
@@ -6,7 +6,7 @@
#include <KernelKit/ProcessScheduler.hpp>
-using namespace HCore;
+using namespace NewOS;
Void ProcessHeader::SetEntrypoint(UIntPtr &imageStart) noexcept {
if (imageStart == 0) this->Crash();
@@ -14,11 +14,11 @@ Void ProcessHeader::SetEntrypoint(UIntPtr &imageStart) noexcept {
this->StackFrame->Rsp = this->StackFrame->Rbp;
}
-namespace HCore {
+namespace NewOS {
bool rt_check_stack(HAL::StackFramePtr stackPtr) {
if (!stackPtr) return false;
if (stackPtr->Rbp == 0 || stackPtr->Rsp == 0) return false;
return true;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/AMD64/HalSMPCoreManager.asm b/Private/HALKit/AMD64/HalSMPCoreManager.asm
index d896a66c..e34b7440 100644
--- a/Private/HALKit/AMD64/HalSMPCoreManager.asm
+++ b/Private/HALKit/AMD64/HalSMPCoreManager.asm
@@ -1,7 +1,7 @@
;; /*
;; * ========================================================
;; *
-;; * HCore
+;; * NewOS
;; * Copyright Mahrouss Logic, all rights reserved.
;; *
;; * ========================================================
diff --git a/Private/HALKit/AMD64/Hypervisor.hpp b/Private/HALKit/AMD64/Hypervisor.hpp
index 07d69e02..82f80ecc 100644
--- a/Private/HALKit/AMD64/Hypervisor.hpp
+++ b/Private/HALKit/AMD64/Hypervisor.hpp
@@ -8,7 +8,7 @@
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
MAKE_STRING_ENUM(HYPERVISOR)
ENUM_STRING(Qemu, "TCGTCGTCGTCG");
ENUM_STRING(KVM, " KVMKVMKVM ");
@@ -22,4 +22,4 @@ ENUM_STRING(Bhyve, "bhyve bhyve ");
ENUM_STRING(Qnx, " QNXQVMBSQG ");
END_STRING_ENUM()
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/AMD64/PCI/Database.cxx b/Private/HALKit/AMD64/PCI/Database.cxx
index 7b78079d..646b2d75 100644
--- a/Private/HALKit/AMD64/PCI/Database.cxx
+++ b/Private/HALKit/AMD64/PCI/Database.cxx
@@ -6,4 +6,4 @@
#include <KernelKit/PCI/Database.hpp>
-namespace HCore {}
+namespace NewOS {}
diff --git a/Private/HALKit/AMD64/PCI/Device.cxx b/Private/HALKit/AMD64/PCI/Device.cxx
index 2b1ec3a5..f5f1d602 100644
--- a/Private/HALKit/AMD64/PCI/Device.cxx
+++ b/Private/HALKit/AMD64/PCI/Device.cxx
@@ -7,36 +7,36 @@
#include <ArchKit/ArchKit.hpp>
#include <KernelKit/PCI/Device.hpp>
-HCore::UInt HCorePCIReadRaw(HCore::UInt bar, HCore::UShort bus,
- HCore::UShort dev, HCore::UShort fun) {
- HCore::UInt target = 0x80000000 | ((HCore::UInt)bus << 16) |
- ((HCore::UInt)dev << 11) | ((HCore::UInt)fun << 8) |
+NewOS::UInt NewOSPCIReadRaw(NewOS::UInt bar, NewOS::UShort bus,
+ NewOS::UShort dev, NewOS::UShort fun) {
+ NewOS::UInt target = 0x80000000 | ((NewOS::UInt)bus << 16) |
+ ((NewOS::UInt)dev << 11) | ((NewOS::UInt)fun << 8) |
(bar & 0xFC);
- HCore::HAL::Out32((HCore::UShort)HCore::PCI::PciConfigKind::ConfigAddress,
+ NewOS::HAL::Out32((NewOS::UShort)NewOS::PCI::PciConfigKind::ConfigAddress,
target);
- return HCore::HAL::In32((HCore::UShort)HCore::PCI::PciConfigKind::ConfigData);
+ return NewOS::HAL::In32((NewOS::UShort)NewOS::PCI::PciConfigKind::ConfigData);
}
-void HCorePCISetCfgTarget(HCore::UInt bar, HCore::UShort bus, HCore::UShort dev,
- HCore::UShort fun) {
- HCore::UInt target = 0x80000000 | ((HCore::UInt)bus << 16) |
- ((HCore::UInt)dev << 11) | ((HCore::UInt)fun << 8) |
+void NewOSPCISetCfgTarget(NewOS::UInt bar, NewOS::UShort bus, NewOS::UShort dev,
+ NewOS::UShort fun) {
+ NewOS::UInt target = 0x80000000 | ((NewOS::UInt)bus << 16) |
+ ((NewOS::UInt)dev << 11) | ((NewOS::UInt)fun << 8) |
(bar & ~3);
- HCore::HAL::Out32((HCore::UShort)HCore::PCI::PciConfigKind::ConfigAddress,
+ NewOS::HAL::Out32((NewOS::UShort)NewOS::PCI::PciConfigKind::ConfigAddress,
target);
}
-namespace HCore::PCI {
+namespace NewOS::PCI {
Device::Device(UShort bus, UShort device, UShort func, UShort bar)
: m_Bus(bus), m_Device(device), m_Function(func), m_Bar(bar) {}
Device::~Device() {}
UInt Device::Read(UInt bar, Size sz) {
- HCorePCISetCfgTarget(bar, m_Bus, m_Device, m_Function);
+ NewOSPCISetCfgTarget(bar, m_Bus, m_Device, m_Function);
if (sz == 4)
return HAL::In32((UShort)PciConfigKind::ConfigData + (m_Bar & 3));
@@ -48,7 +48,7 @@ UInt Device::Read(UInt bar, Size sz) {
}
void Device::Write(UInt bar, UIntPtr data, Size sz) {
- HCorePCISetCfgTarget(bar, m_Bus, m_Device, m_Function);
+ NewOSPCISetCfgTarget(bar, m_Bus, m_Device, m_Function);
if (sz == 4)
HAL::Out32((UShort)PciConfigKind::ConfigData + (m_Bar & 3), (UInt)data);
@@ -59,31 +59,31 @@ void Device::Write(UInt bar, UIntPtr data, Size sz) {
}
UShort Device::DeviceId() {
- return (UShort)(HCorePCIReadRaw(0x0 >> 16, m_Bus, m_Device, m_Function));
+ return (UShort)(NewOSPCIReadRaw(0x0 >> 16, m_Bus, m_Device, m_Function));
}
UShort Device::VendorId() {
- return (UShort)(HCorePCIReadRaw(0x0, m_Bus, m_Device, m_Function) >> 16);
+ return (UShort)(NewOSPCIReadRaw(0x0, m_Bus, m_Device, m_Function) >> 16);
}
UShort Device::InterfaceId() {
- return (UShort)(HCorePCIReadRaw(0x0, m_Bus, m_Device, m_Function) >> 16);
+ return (UShort)(NewOSPCIReadRaw(0x0, m_Bus, m_Device, m_Function) >> 16);
}
UChar Device::Class() {
- return (UChar)(HCorePCIReadRaw(0x08, m_Bus, m_Device, m_Function) >> 24);
+ return (UChar)(NewOSPCIReadRaw(0x08, m_Bus, m_Device, m_Function) >> 24);
}
UChar Device::Subclass() {
- return (UChar)(HCorePCIReadRaw(0x08, m_Bus, m_Device, m_Function) >> 16);
+ return (UChar)(NewOSPCIReadRaw(0x08, m_Bus, m_Device, m_Function) >> 16);
}
UChar Device::ProgIf() {
- return (UChar)(HCorePCIReadRaw(0x08, m_Bus, m_Device, m_Function) >> 8);
+ return (UChar)(NewOSPCIReadRaw(0x08, m_Bus, m_Device, m_Function) >> 8);
}
UChar Device::HeaderType() {
- return (UChar)(HCorePCIReadRaw(0xC, m_Bus, m_Device, m_Function) >> 16);
+ return (UChar)(NewOSPCIReadRaw(0xC, m_Bus, m_Device, m_Function) >> 16);
}
void Device::EnableMmio() {
@@ -106,4 +106,4 @@ UShort Device::Vendor() {
}
Device::operator bool() { return VendorId() != (UShort)PciConfigKind::Invalid; }
-} // namespace HCore::PCI
+} // namespace NewOS::PCI
diff --git a/Private/HALKit/AMD64/PCI/Dma.cxx b/Private/HALKit/AMD64/PCI/Dma.cxx
index 5b754ea4..1efef53b 100644
--- a/Private/HALKit/AMD64/PCI/Dma.cxx
+++ b/Private/HALKit/AMD64/PCI/Dma.cxx
@@ -6,7 +6,7 @@
#include <KernelKit/PCI/Dma.hpp>
-namespace HCore {
+namespace NewOS {
DMAWrapper::operator bool() { return m_Address; }
bool DMAWrapper::operator!() { return !m_Address; }
@@ -60,4 +60,4 @@ DMAWrapper &DMAWrapper::operator=(voidPtr Ptr) {
m_Address = Ptr;
return *this;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/AMD64/PCI/Express.cxx b/Private/HALKit/AMD64/PCI/Express.cxx
index 9633711e..c5be5786 100644
--- a/Private/HALKit/AMD64/PCI/Express.cxx
+++ b/Private/HALKit/AMD64/PCI/Express.cxx
@@ -6,4 +6,4 @@
#include <KernelKit/PCI/Express.hpp>
-namespace HCore {}
+namespace NewOS {}
diff --git a/Private/HALKit/AMD64/PCI/Iterator.cxx b/Private/HALKit/AMD64/PCI/Iterator.cxx
index 98cb8016..eb3f7b13 100644
--- a/Private/HALKit/AMD64/PCI/Iterator.cxx
+++ b/Private/HALKit/AMD64/PCI/Iterator.cxx
@@ -9,7 +9,7 @@
#define PCI_ITERATOR_FIND_AND_UNWRAP(DEV, SZ) \
if (DEV.Leak()) return DEV.Leak();
-namespace HCore::PCI {
+namespace NewOS::PCI {
Iterator::Iterator(const Types::PciDeviceKind &type) {
// probe devices.
for (int bus = 0; bus < ME_BUS_COUNT; ++bus) {
@@ -31,4 +31,4 @@ Ref<PCI::Device> Iterator::operator[](const Size &sz) {
PCI_ITERATOR_FIND_AND_UNWRAP(m_Devices[sz], sz);
return {};
}
-} // namespace HCore::PCI
+} // namespace NewOS::PCI
diff --git a/Private/HALKit/AMD64/Processor.hpp b/Private/HALKit/AMD64/Processor.hpp
index 4e104b40..78d45c2e 100644
--- a/Private/HALKit/AMD64/Processor.hpp
+++ b/Private/HALKit/AMD64/Processor.hpp
@@ -32,7 +32,7 @@
#define kGdtCodeSelector 0x08
#define kVirtualAddressStartOffset 0x100
-namespace HCore {
+namespace NewOS {
namespace Detail::AMD64 {
struct PACKED InterruptDescriptorAMD64 final {
UInt16 OffsetLow; // offset bits 0..15
@@ -45,9 +45,9 @@ struct PACKED InterruptDescriptorAMD64 final {
UInt32 Zero; // reserved
};
} // namespace Detail::AMD64
-} // namespace HCore
+} // namespace NewOS
-namespace HCore::HAL {
+namespace NewOS::HAL {
EXTERN_C UChar In8(UInt16 port);
EXTERN_C UShort In16(UInt16 port);
EXTERN_C UInt In32(UInt16 port);
@@ -152,7 +152,7 @@ EXTERN_C void _ke_power_on_self_test(void);
@brief Global descriptor table entry, either null, code or data.
*/
-struct PACKED HCoreGDTRecord final {
+struct PACKED NewOSGDTRecord final {
UInt16 Limit0;
UInt16 Base0;
UInt8 Base1;
@@ -161,25 +161,25 @@ struct PACKED HCoreGDTRecord final {
UInt8 Base2;
};
-struct PACKED ALIGN(0x1000) HCoreGDT final {
- HCoreGDTRecord Null;
- HCoreGDTRecord KernCode;
- HCoreGDTRecord KernData;
- HCoreGDTRecord UserNull;
- HCoreGDTRecord UserCode;
- HCoreGDTRecord UserData;
+struct PACKED ALIGN(0x1000) NewOSGDT final {
+ NewOSGDTRecord Null;
+ NewOSGDTRecord KernCode;
+ NewOSGDTRecord KernData;
+ NewOSGDTRecord UserNull;
+ NewOSGDTRecord UserCode;
+ NewOSGDTRecord UserData;
};
} // namespace Detail
-} // namespace HCore::HAL
+} // namespace NewOS::HAL
-EXTERN_C void idt_handle_system_call(HCore::UIntPtr rsp);
-EXTERN_C void idt_handle_generic(HCore::UIntPtr rsp);
-EXTERN_C void idt_handle_gpf(HCore::UIntPtr rsp);
-EXTERN_C void idt_handle_math(HCore::UIntPtr rsp);
-EXTERN_C void idt_handle_pf(HCore::UIntPtr rsp);
+EXTERN_C void idt_handle_system_call(NewOS::UIntPtr rsp);
+EXTERN_C void idt_handle_generic(NewOS::UIntPtr rsp);
+EXTERN_C void idt_handle_gpf(NewOS::UIntPtr rsp);
+EXTERN_C void idt_handle_math(NewOS::UIntPtr rsp);
+EXTERN_C void idt_handle_pf(NewOS::UIntPtr rsp);
-EXTERN_C void hal_load_idt(HCore::HAL::Register64 ptr);
-EXTERN_C void hal_load_gdt(HCore::HAL::RegisterGDT ptr);
+EXTERN_C void hal_load_idt(NewOS::HAL::Register64 ptr);
+EXTERN_C void hal_load_gdt(NewOS::HAL::RegisterGDT ptr);
/// @brief Maximum size of the IDT.
#define kKernelIdtSize 0x100
diff --git a/Private/HALKit/AMD64/Storage/ATA.cxx b/Private/HALKit/AMD64/Storage/ATA.cxx
index 699876b7..d9744153 100644
--- a/Private/HALKit/AMD64/Storage/ATA.cxx
+++ b/Private/HALKit/AMD64/Storage/ATA.cxx
@@ -18,8 +18,8 @@
#include <Builtins/ATA/Defines.hxx>
#include <ArchKit/ArchKit.hpp>
-using namespace HCore;
-using namespace HCore::HAL;
+using namespace NewOS;
+using namespace NewOS::HAL;
/// bugs: 0
diff --git a/Private/HALKit/AXP/CoreSyscallHandlerDEC.cpp b/Private/HALKit/AXP/CoreSyscallHandlerDEC.cpp
index 49a0062c..a0d1b13e 100644
--- a/Private/HALKit/AXP/CoreSyscallHandlerDEC.cpp
+++ b/Private/HALKit/AXP/CoreSyscallHandlerDEC.cpp
@@ -7,12 +7,12 @@
#include <ArchKit/ArchKit.hpp>
#include <HALKit/Alpha/Processor.hpp>
-HCore::Array<void (*)(HCore::Int32 id, HCore::HAL::StackFrame *),
+NewOS::Array<void (*)(NewOS::Int32 id, NewOS::HAL::StackFrame *),
kKernelMaxSystemCalls>
kSyscalls;
-extern "C" void rt_syscall_handle(HCore::HAL::StackFrame *stack) {
- for (HCore::SizeT index = 0UL; index < kKernelMaxSystemCalls; ++index) {
+extern "C" void rt_syscall_handle(NewOS::HAL::StackFrame *stack) {
+ for (NewOS::SizeT index = 0UL; index < kKernelMaxSystemCalls; ++index) {
(kSyscalls[index].Leak().Leak())(stack->ID, stack);
}
}
diff --git a/Private/HALKit/PowerPC/HalCoreSyscallHandlerPowerPC.cpp b/Private/HALKit/PowerPC/HalCoreSyscallHandlerPowerPC.cpp
index eac04e47..322cb604 100644
--- a/Private/HALKit/PowerPC/HalCoreSyscallHandlerPowerPC.cpp
+++ b/Private/HALKit/PowerPC/HalCoreSyscallHandlerPowerPC.cpp
@@ -7,12 +7,12 @@
#include <ArchKit/ArchKit.hpp>
#include <NewKit/Array.hpp>
-HCore::Array<void (*)(HCore::Int32 id, HCore::HAL::StackFrame *),
+NewOS::Array<void (*)(NewOS::Int32 id, NewOS::HAL::StackFrame *),
kKernelMaxSystemCalls>
kSyscalls;
-extern "C" void rt_syscall_handle(HCore::HAL::StackFrame *stack) {
- for (HCore::SizeT index = 0UL; index < kKernelMaxSystemCalls; ++index) {
+extern "C" void rt_syscall_handle(NewOS::HAL::StackFrame *stack) {
+ for (NewOS::SizeT index = 0UL; index < kKernelMaxSystemCalls; ++index) {
(kSyscalls[index].Leak().Leak())(stack->ID, stack);
}
}
diff --git a/Private/HALKit/PowerPC/HalHardware.cxx b/Private/HALKit/PowerPC/HalHardware.cxx
index 49e85138..9fc278a6 100644
--- a/Private/HALKit/PowerPC/HalHardware.cxx
+++ b/Private/HALKit/PowerPC/HalHardware.cxx
@@ -7,7 +7,7 @@
#include <HALKit/PowerPC/Processor.hpp>
#include <KernelKit/DebugOutput.hpp>
-namespace HCore {
+namespace NewOS {
namespace HAL {
UIntPtr hal_alloc_page(bool rw, bool user) { return 0; }
} // namespace HAL
@@ -31,4 +31,4 @@ void ke_com_print(const Char* bytes) {
++index;
}
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/HALKit/PowerPC/HalThread.cxx b/Private/HALKit/PowerPC/HalThread.cxx
index 585ae706..af8bcc6f 100644
--- a/Private/HALKit/PowerPC/HalThread.cxx
+++ b/Private/HALKit/PowerPC/HalThread.cxx
@@ -10,4 +10,4 @@
extern "C" void hal_flush_tlb() {}
extern "C" void rt_wait_400ns() {}
-extern "C" HCore::HAL::StackFramePtr rt_get_current_context() { return nullptr; }
+extern "C" NewOS::HAL::StackFramePtr rt_get_current_context() { return nullptr; }
diff --git a/Private/HALKit/PowerPC/Processor.hpp b/Private/HALKit/PowerPC/Processor.hpp
index e5f04455..be929fd7 100644
--- a/Private/HALKit/PowerPC/Processor.hpp
+++ b/Private/HALKit/PowerPC/Processor.hpp
@@ -11,7 +11,7 @@
#define __aligned __attribute__((aligned(4)))
-namespace HCore::HAL {
+namespace NewOS::HAL {
typedef UIntPtr Reg;
struct __aligned StackFrame {
@@ -34,8 +34,8 @@ inline void rt_halt() {
}
inline void rt_cli() {}
-} // namespace HCore::HAL
+} // namespace NewOS::HAL
-extern "C" void int_handle_math(HCore::UIntPtr sp);
-extern "C" void int_handle_pf(HCore::UIntPtr sp);
+extern "C" void int_handle_math(NewOS::UIntPtr sp);
+extern "C" void int_handle_pf(NewOS::UIntPtr sp);
extern "C" void* __ppc_alloca(size_t sz);
diff --git a/Private/HALKit/RISCV/Hart.hxx b/Private/HALKit/RISCV/Hart.hxx
index fbf7dca1..9bf8668f 100644
--- a/Private/HALKit/RISCV/Hart.hxx
+++ b/Private/HALKit/RISCV/Hart.hxx
@@ -15,4 +15,4 @@
#include <NewKit/Defines.hpp>
-typedef HCore::Int32 Rv64HartType;
+typedef NewOS::Int32 Rv64HartType;
diff --git a/Private/KernelKit/CodeManager.hpp b/Private/KernelKit/CodeManager.hpp
index ed42517a..5b06e4a4 100644
--- a/Private/KernelKit/CodeManager.hpp
+++ b/Private/KernelKit/CodeManager.hpp
@@ -20,7 +20,7 @@
#define kUPPNameLen 64
-namespace HCore {
+namespace NewOS {
/// \brief Much like Mac OS's UPP.
/// This is read-only by design.
/// It handles different kind of code.
@@ -30,4 +30,4 @@ typedef struct UniversalProcedureTable final {
const VoidPtr TRAP;
const SizeT ARCH;
} PACKED UniversalProcedureTableType;
-} // namespace HCore \ No newline at end of file
+} // namespace NewOS \ No newline at end of file
diff --git a/Private/KernelKit/DebugOutput.hpp b/Private/KernelKit/DebugOutput.hpp
index 457bc9d1..3f88fd0e 100644
--- a/Private/KernelKit/DebugOutput.hpp
+++ b/Private/KernelKit/DebugOutput.hpp
@@ -25,7 +25,7 @@
#define kDebugTeam 43
#define kDebugEOP 49
-namespace HCore {
+namespace NewOS {
// @brief Emulates a VT100 terminal.
class TerminalDevice final : public DeviceInterface<const Char *> {
public:
@@ -135,7 +135,7 @@ class DebuggerPortHeader final {
Int16 fPort[kDebugMaxPorts];
Int16 fBoundCnt;
};
-} // namespace HCore
+} // namespace NewOS
#ifdef kcout
#undef kcout
diff --git a/Private/KernelKit/DeviceManager.hpp b/Private/KernelKit/DeviceManager.hpp
index 4eada620..10d23604 100644
--- a/Private/KernelKit/DeviceManager.hpp
+++ b/Private/KernelKit/DeviceManager.hpp
@@ -14,7 +14,7 @@
#pragma once
-/* HCore device interface manager. */
+/* NewOS device interface manager. */
/* @file KernelKit/DeviceManager.hpp */
/* @brief Device abstraction and I/O buffer. */
@@ -24,7 +24,7 @@
// Last Rev
// Sat Feb 24 CET 2024
-namespace HCore {
+namespace NewOS {
template <typename T>
class DeviceInterface;
@@ -105,4 +105,4 @@ enum {
kDeviceTypeMedia,
kDeviceTypeCount,
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/KernelKit/DriveManager.hxx b/Private/KernelKit/DriveManager.hxx
index 8d0289aa..36e0b681 100644
--- a/Private/KernelKit/DriveManager.hxx
+++ b/Private/KernelKit/DriveManager.hxx
@@ -17,7 +17,7 @@
#define kDriveInvalidID -1
#define kDriveNameLen 32
-namespace HCore {
+namespace NewOS {
enum {
kInvalidDrive = -1,
kBlockDevice = 0xAD,
@@ -103,6 +103,6 @@ class MountpointInterface final {
private:
DriveDevicePtr mA, mB, mC, mD = nullptr;
};
-} // namespace HCore
+} // namespace NewOS
#endif /* ifndef __DRIVE_MANAGER__ */
diff --git a/Private/KernelKit/FileManager.hpp b/Private/KernelKit/FileManager.hpp
index 87de3d9e..1ce8d629 100644
--- a/Private/KernelKit/FileManager.hpp
+++ b/Private/KernelKit/FileManager.hpp
@@ -39,7 +39,7 @@
/// refer to first enum.
#define kFileOpsCount 4
-namespace HCore {
+namespace NewOS {
enum {
kFileWriteAll = 100,
kFileReadAll = 101,
@@ -244,6 +244,6 @@ FileStream<Encoding, Class>::FileStream(const Encoding *path,
template <typename Encoding, typename Class>
FileStream<Encoding, Class>::~FileStream() = default;
-} // namespace HCore
+} // namespace NewOS
-#define node_cast(PTR) reinterpret_cast<HCore::NodePtr>(PTR)
+#define node_cast(PTR) reinterpret_cast<NewOS::NodePtr>(PTR)
diff --git a/Private/KernelKit/Framebuffer.hpp b/Private/KernelKit/Framebuffer.hpp
index 397f62d0..d399f382 100644
--- a/Private/KernelKit/Framebuffer.hpp
+++ b/Private/KernelKit/Framebuffer.hpp
@@ -10,7 +10,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore {
+namespace NewOS {
enum class FramebufferColorKind : UChar {
RGB32,
RGB16,
@@ -75,12 +75,12 @@ const UInt32 kRgbGreen = 0x0000FF00;
const UInt32 kRgbBlue = 0x00FF0000;
const UInt32 kRgbBlack = 0x00000000;
const UInt32 kRgbWhite = 0xFFFFFFFF;
-} // namespace HCore
+} // namespace NewOS
/***********************************************************************************/
/// Color macros.
/***********************************************************************************/
-#define RGB(R, G, B) (HCore::UInt32)(0x##R##G##B)
+#define RGB(R, G, B) (NewOS::UInt32)(0x##R##G##B)
#endif /* ifndef __INC_FB_HPP__ */
diff --git a/Private/KernelKit/HError.hpp b/Private/KernelKit/HError.hpp
index 4b943296..6885003f 100644
--- a/Private/KernelKit/HError.hpp
+++ b/Private/KernelKit/HError.hpp
@@ -9,7 +9,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/ErrorID.hpp>
-namespace HCore {
+namespace NewOS {
typedef Int32 HError;
inline constexpr HError kErrorSuccess = 0;
@@ -34,10 +34,10 @@ inline constexpr HError kErrorForkAlreadyExists = 50;
inline constexpr HError kErrorUnimplemented = 0;
Boolean ke_bug_check(void) noexcept;
-} // namespace HCore
+} // namespace NewOS
-#define DbgOk() (kLastError == HCore::kErrorSuccess)
-#define DbgFailed() (kLastError != HCore::kErrorSuccess)
+#define DbgOk() (kLastError == NewOS::kErrorSuccess)
+#define DbgFailed() (kLastError != NewOS::kErrorSuccess)
#define DbgLastError() kLastError
-inline HCore::HError kLastError = 0;
+inline NewOS::HError kLastError = 0;
diff --git a/Private/KernelKit/KernelHeap.hpp b/Private/KernelKit/KernelHeap.hpp
index f8c1c9c3..69c84b7f 100644
--- a/Private/KernelKit/KernelHeap.hpp
+++ b/Private/KernelKit/KernelHeap.hpp
@@ -12,9 +12,9 @@
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
Int32 ke_delete_ke_heap(voidPtr allocatedPtr);
Boolean ke_is_valid_heap(VoidPtr ptr);
voidPtr ke_new_ke_heap(SizeT sz, const bool rw, const bool user);
Boolean ke_protect_ke_heap(VoidPtr heapPtr);
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/KernelKit/LoaderInterface.hpp b/Private/KernelKit/LoaderInterface.hpp
index 5beb403f..c4634ca4 100644
--- a/Private/KernelKit/LoaderInterface.hpp
+++ b/Private/KernelKit/LoaderInterface.hpp
@@ -11,7 +11,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/ErrorOr.hpp>
-namespace HCore {
+namespace NewOS {
/// @brief This interface is used to make loader contracts (MSCOFF, PEF).
/// @author @Amlal-El-Mahrouss
class LoaderInterface {
@@ -28,4 +28,4 @@ class LoaderInterface {
virtual _Output ErrorOr<VoidPtr> FindStart() = 0;
virtual _Output VoidPtr FindSymbol(_Input const char* name, _Input Int32 kind) = 0;
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/KernelKit/LockDelegate.hpp b/Private/KernelKit/LockDelegate.hpp
index 0fd9ba63..07f492a8 100644
--- a/Private/KernelKit/LockDelegate.hpp
+++ b/Private/KernelKit/LockDelegate.hpp
@@ -12,7 +12,7 @@
#define kLockDone (200U) /* job is done */
#define kLockTimedOut (100U) /* job has timed out */
-namespace HCore
+namespace NewOS
{
/// @brief Lock condition pointer.
typedef Boolean* LockPtr;
@@ -61,4 +61,4 @@ class LockDelegate final
private:
Atom<UInt> m_LockStatus;
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/KernelKit/MSDOS.hpp b/Private/KernelKit/MSDOS.hpp
index aa7f9b8c..1fe99a60 100644
--- a/Private/KernelKit/MSDOS.hpp
+++ b/Private/KernelKit/MSDOS.hpp
@@ -3,7 +3,7 @@
Copyright Mahrouss Logic
File: MSDOS.hpp
- Purpose: MS-DOS header for HCore.
+ Purpose: MS-DOS header for NewOS.
Revision History:
@@ -23,11 +23,11 @@
#define kMagMz0 'M'
#define kMagMz1 'Z'
-typedef HCore::UInt32 DosWord;
-typedef HCore::Long DosLong;
+typedef NewOS::UInt32 DosWord;
+typedef NewOS::Long DosLong;
typedef struct _DosHeader {
- HCore::UInt8 eMagic[2];
+ NewOS::UInt8 eMagic[2];
DosWord eMagLen;
DosWord ePagesCount;
DosWord eCrlc;
@@ -48,7 +48,7 @@ typedef struct _DosHeader {
DosLong eLfanew;
} DosHeader, *DosHeaderPtr;
-namespace HCore {
+namespace NewOS {
/// @brief Find the PE header inside the the blob.
inline auto rt_find_exec_header(DosHeaderPtr ptrDos) -> VoidPtr {
if (!ptrDos) return nullptr;
@@ -57,6 +57,6 @@ inline auto rt_find_exec_header(DosHeaderPtr ptrDos) -> VoidPtr {
return (VoidPtr)(&ptrDos->eLfanew + 1);
}
-} // namespace HCore
+} // namespace NewOS
#endif /* ifndef __MSDOS_EXEC__ */
diff --git a/Private/KernelKit/PCI/Database.hpp b/Private/KernelKit/PCI/Database.hpp
index 773677d6..b79f7b57 100644
--- a/Private/KernelKit/PCI/Database.hpp
+++ b/Private/KernelKit/PCI/Database.hpp
@@ -8,7 +8,7 @@
#include <KernelKit/PCI/Device.hpp>
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
namespace Types {
// https://wiki.osdev.org/PCI
enum class PciDeviceKind : UChar {
@@ -32,4 +32,4 @@ namespace HCore {
Invalid = Unassgined,
};
} // namespace Types
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/KernelKit/PCI/Device.hpp b/Private/KernelKit/PCI/Device.hpp
index 08371f12..c73ca068 100644
--- a/Private/KernelKit/PCI/Device.hpp
+++ b/Private/KernelKit/PCI/Device.hpp
@@ -7,7 +7,7 @@
#include <NewKit/Defines.hpp>
-namespace HCore::PCI
+namespace NewOS::PCI
{
enum class PciConfigKind : UShort
{
@@ -74,8 +74,8 @@ namespace HCore::PCI
UShort m_Bar;
};
-} // namespace HCore::PCI
+} // namespace NewOS::PCI
-extern "C" void LumiaPCISetCfgTarget(HCore::UInt bar);
-extern "C" HCore::UInt LumiaPCIReadRaw(HCore::UInt bar);
+extern "C" void LumiaPCISetCfgTarget(NewOS::UInt bar);
+extern "C" NewOS::UInt LumiaPCIReadRaw(NewOS::UInt bar);
diff --git a/Private/KernelKit/PCI/Dma.hpp b/Private/KernelKit/PCI/Dma.hpp
index d5df4c3d..1e1b5036 100644
--- a/Private/KernelKit/PCI/Dma.hpp
+++ b/Private/KernelKit/PCI/Dma.hpp
@@ -12,7 +12,7 @@
#include <NewKit/OwnPtr.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore {
+namespace NewOS {
enum class DmaKind {
PCI, // Bus mastering is required to be turned on. Basiaclly a request
// control system. 64-Bit access depends on the PAE bit and the device
@@ -70,6 +70,6 @@ class DMAFactory final {
public:
static OwnPtr<IOBuf<Char *>> Construct(OwnPtr<DMAWrapper> &dma);
};
-} // namespace HCore
+} // namespace NewOS
#include <KernelKit/PCI/Dma.inl>
diff --git a/Private/KernelKit/PCI/Dma.inl b/Private/KernelKit/PCI/Dma.inl
index ac0214af..5f7e1379 100644
--- a/Private/KernelKit/PCI/Dma.inl
+++ b/Private/KernelKit/PCI/Dma.inl
@@ -4,7 +4,7 @@
------------------------------------------- */
-namespace HCore
+namespace NewOS
{
template<class T>
T* DMAWrapper::operator->()
diff --git a/Private/KernelKit/PCI/IO-Impl-AMD64.inl b/Private/KernelKit/PCI/IO-Impl-AMD64.inl
index f720f2b6..195ebca1 100644
--- a/Private/KernelKit/PCI/IO-Impl-AMD64.inl
+++ b/Private/KernelKit/PCI/IO-Impl-AMD64.inl
@@ -12,7 +12,7 @@
------------------------------------------- */
-namespace HCore {
+namespace NewOS {
template <SizeT Sz>
template <typename T>
T IOArray<Sz>::In(SizeT index) {
@@ -44,4 +44,4 @@ void IOArray<Sz>::Out(SizeT index, T value) {
break;
}
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/KernelKit/PCI/IO.hpp b/Private/KernelKit/PCI/IO.hpp
index a58bd955..87a29b78 100644
--- a/Private/KernelKit/PCI/IO.hpp
+++ b/Private/KernelKit/PCI/IO.hpp
@@ -11,7 +11,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore {
+namespace NewOS {
template <SizeT Sz>
class IOArray final {
public:
@@ -40,7 +40,7 @@ class IOArray final {
};
using IOArray16 = IOArray<16>;
-} // namespace HCore
+} // namespace NewOS
#ifdef __x86_64__
#include <KernelKit/PCI/IO-Impl-AMD64.inl>
diff --git a/Private/KernelKit/PCI/Iterator.hpp b/Private/KernelKit/PCI/Iterator.hpp
index 89e1f246..f1069fda 100644
--- a/Private/KernelKit/PCI/Iterator.hpp
+++ b/Private/KernelKit/PCI/Iterator.hpp
@@ -11,7 +11,7 @@
#define ME_DEVICE_COUNT (33)
#define ME_FUNCTION_COUNT (8)
-namespace HCore::PCI {
+namespace NewOS::PCI {
class Iterator final {
public:
Iterator() = delete;
@@ -31,6 +31,6 @@ namespace HCore::PCI {
private:
Array<PCI::Device, ME_BUS_COUNT> m_Devices;
};
-} // namespace HCore::PCI
+} // namespace NewOS::PCI
#endif // __PCI_ITERATOR_HPP__
diff --git a/Private/KernelKit/PCI/PCI.hpp b/Private/KernelKit/PCI/PCI.hpp
index c93150b2..65e199ad 100644
--- a/Private/KernelKit/PCI/PCI.hpp
+++ b/Private/KernelKit/PCI/PCI.hpp
@@ -14,7 +14,7 @@
#define PCI_FUNC_COUNT (8)
#define PCI_BUS_COUNT (255)
-namespace HCore::PCI {
+namespace NewOS::PCI {
// model
struct DeviceHeader {
UInt16 VendorId;
@@ -50,4 +50,4 @@ namespace HCore::PCI {
Detail::BAR BAR4;
Detail::BAR BAR5;
};
-} // namespace HCore::PCI
+} // namespace NewOS::PCI
diff --git a/Private/KernelKit/PE.hpp b/Private/KernelKit/PE.hpp
index 3fd4f965..f397ff48 100644
--- a/Private/KernelKit/PE.hpp
+++ b/Private/KernelKit/PE.hpp
@@ -3,7 +3,7 @@
Copyright Mahrouss Logic
File: PE.hpp
- Purpose: Portable Executable for HCore.
+ Purpose: Portable Executable for NewOS.
Revision History:
@@ -19,10 +19,10 @@
namespace Detail
{
- typedef HCore::UIntPtr PE_QWORD;
- typedef HCore::UInt32 PE_DWORD;
- typedef HCore::UInt16 PE_WORD;
- typedef HCore::UChar PE_BYTE;
+ typedef NewOS::UIntPtr PE_QWORD;
+ typedef NewOS::UInt32 PE_DWORD;
+ typedef NewOS::UInt16 PE_WORD;
+ typedef NewOS::UChar PE_BYTE;
} // namespace Detail
#define kPeMagic 0x00004550
diff --git a/Private/KernelKit/PEF.hpp b/Private/KernelKit/PEF.hpp
index df95d82e..a86cd154 100644
--- a/Private/KernelKit/PEF.hpp
+++ b/Private/KernelKit/PEF.hpp
@@ -3,7 +3,7 @@
Copyright Mahrouss Logic
File: PEF.hpp
- Purpose: Preferred Executable Format for HCore.
+ Purpose: Preferred Executable Format for NewOS.
Revision History:
@@ -32,7 +32,7 @@
/// The PEF also uses the x64 PE calling convention and ABI.
/// It's just that the container are different.
-namespace HCore {
+namespace NewOS {
enum {
kPefArchIntel86S,
kPefArchAMD64,
@@ -85,7 +85,7 @@ enum {
kPefZero = 0xE,
kPefLinkerID = 0x1,
};
-} // namespace HCore
+} // namespace NewOS
#define kPefExt ".exe"
#define kPefDylibExt ".dll"
@@ -93,7 +93,7 @@ enum {
#define kPefObjectExt ".obj"
#define kPefDebugExt ".dbg"
-// HCore System Binary Interface.
+// NewOS System Binary Interface.
#define kPefAbi (0xDEAD2)
#define kPefStart "__start"
diff --git a/Private/KernelKit/PEFCodeManager.hxx b/Private/KernelKit/PEFCodeManager.hxx
index e952d40f..45b475f5 100644
--- a/Private/KernelKit/PEFCodeManager.hxx
+++ b/Private/KernelKit/PEFCodeManager.hxx
@@ -13,7 +13,7 @@
#define kPefApplicationMime "application/x-hcore-exec"
-namespace HCore {
+namespace NewOS {
///
/// \name PEFLoader
/// \brief PEF loader class.
@@ -54,6 +54,6 @@ class PEFLoader : public LoaderInterface {
namespace Utils {
bool execute_from_image(PEFLoader &exec) noexcept;
} // namespace Utils
-} // namespace HCore
+} // namespace NewOS
#endif // ifndef _INC_CODE_MANAGER_PEF_
diff --git a/Private/KernelKit/PEFSharedObject.hxx b/Private/KernelKit/PEFSharedObject.hxx
index 0684b2a7..41ee2b97 100644
--- a/Private/KernelKit/PEFSharedObject.hxx
+++ b/Private/KernelKit/PEFSharedObject.hxx
@@ -1,7 +1,7 @@
/*
* ========================================================
*
- * HCore
+ * NewOS
* Copyright Mahrouss Logic, all rights reserved.
*
* ========================================================
@@ -15,7 +15,7 @@
#include <KernelKit/PEFCodeManager.hxx>
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
/// @brief Pure implementation, missing method/function handler.
extern "C" void __mh_purecall(void);
@@ -87,6 +87,6 @@ class SharedObject final {
};
typedef SharedObject *SharedObjectPtr;
-} // namespace HCore
+} // namespace NewOS
#endif /* ifndef __KERNELKIT_SHARED_OBJECT_HXX__ */
diff --git a/Private/KernelKit/PermissionSelector.hxx b/Private/KernelKit/PermissionSelector.hxx
index c5a55fee..c252c9d0 100644
--- a/Private/KernelKit/PermissionSelector.hxx
+++ b/Private/KernelKit/PermissionSelector.hxx
@@ -20,7 +20,7 @@
// hash 'user@host:password' -> base64 encoded data
// use this data to then fetch specific data.
-namespace HCore {
+namespace NewOS {
enum class RingKind {
kRingUser = 3,
kRingDriver = 2,
@@ -49,6 +49,6 @@ class PermissionSelector final {
private:
RingKind fRing;
};
-} // namespace HCore
+} // namespace NewOS
#endif /* ifndef _INC_PERMISSION_SEL_HPP */
diff --git a/Private/KernelKit/ProcessScheduler.hpp b/Private/KernelKit/ProcessScheduler.hpp
index 1b55be4a..0cc531b9 100644
--- a/Private/KernelKit/ProcessScheduler.hpp
+++ b/Private/KernelKit/ProcessScheduler.hpp
@@ -23,7 +23,7 @@
////////////////////////////////////////////////////
-namespace HCore {
+namespace NewOS {
class ProcessHeader;
class ProcessTeam;
class ProcessScheduler;
@@ -124,7 +124,7 @@ class ProcessHeader final {
void SetEntrypoint(UIntPtr &imageStart) noexcept;
public:
- Char Name[kProcessLen] = {"HCore Process"};
+ Char Name[kProcessLen] = {"NewOS Process"};
ProcessSubsystem SubSystem{0};
ProcessSelector Selector{ProcessSelector::kRingUser};
HAL::StackFramePtr StackFrame{nullptr};
@@ -250,7 +250,7 @@ class ProcessHelper final {
};
const Int32 &rt_get_exit_code() noexcept;
-} // namespace HCore
+} // namespace NewOS
#include <KernelKit/ThreadLocalStorage.hxx>
diff --git a/Private/KernelKit/SMPManager.hpp b/Private/KernelKit/SMPManager.hpp
index c207be82..b4d04dde 100644
--- a/Private/KernelKit/SMPManager.hpp
+++ b/Private/KernelKit/SMPManager.hpp
@@ -16,7 +16,7 @@
#define kMaxHarts 8
-namespace HCore {
+namespace NewOS {
using ThreadID = UInt32;
enum ThreadKind {
@@ -117,6 +117,6 @@ Void rt_wakeup_thread(HAL::StackFramePtr stack);
/// @brief makes thread sleep.
/// hooks and hangs thread to prevent code from executing.
Void rt_hang_thread(HAL::StackFramePtr stack);
-} // namespace HCore
+} // namespace NewOS
#endif // !__SMP_MANAGER__
diff --git a/Private/KernelKit/Semaphore.hpp b/Private/KernelKit/Semaphore.hpp
index 9b9dbef3..0e41aa49 100644
--- a/Private/KernelKit/Semaphore.hpp
+++ b/Private/KernelKit/Semaphore.hpp
@@ -9,7 +9,7 @@
#include <NewKit/Defines.hpp>
#include <CompilerKit/CompilerKit.hxx>
-namespace HCore
+namespace NewOS
{
class ProcessHeader;
diff --git a/Private/KernelKit/ThreadLocalStorage.hxx b/Private/KernelKit/ThreadLocalStorage.hxx
index 09017fc0..4abd9ecd 100644
--- a/Private/KernelKit/ThreadLocalStorage.hxx
+++ b/Private/KernelKit/ThreadLocalStorage.hxx
@@ -29,21 +29,21 @@ T *tls_new_class(Args &&...args);
/// @brief Thread Information Block for Local Storage.
/// Located in GS on AMD64, Virtual Address 0x10000 (64x0, 32x0, ARM64)
struct PACKED ThreadInformationBlock final {
- HCore::Char Cookie[kTLSCookieLen];
- HCore::UIntPtr StartCode; // Start Address
- HCore::UIntPtr StartData; // Allocation Heap
- HCore::UIntPtr StartStack; // Stack Pointer.
- HCore::Int32 ThreadID; // Thread execution ID.
+ NewOS::Char Cookie[kTLSCookieLen];
+ NewOS::UIntPtr StartCode; // Start Address
+ NewOS::UIntPtr StartData; // Allocation Heap
+ NewOS::UIntPtr StartStack; // Stack Pointer.
+ NewOS::Int32 ThreadID; // Thread execution ID.
};
/// @brief TLS install TIB
-EXTERN_C void rt_install_tib(ThreadInformationBlock *pTib, HCore::VoidPtr pPib);
+EXTERN_C void rt_install_tib(ThreadInformationBlock *pTib, NewOS::VoidPtr pPib);
///! @brief Cookie Sanity check.
-HCore::Boolean tls_check_tib(ThreadInformationBlock* ptr);
+NewOS::Boolean tls_check_tib(ThreadInformationBlock* ptr);
/// @brief TLS check system call
-EXTERN_C HCore::Void tls_check_syscall_impl(HCore::HAL::StackFramePtr stackPtr) noexcept;
+EXTERN_C NewOS::Void tls_check_syscall_impl(NewOS::HAL::StackFramePtr stackPtr) noexcept;
#include <KernelKit/ThreadLocalStorage.inl>
diff --git a/Private/KernelKit/ThreadLocalStorage.inl b/Private/KernelKit/ThreadLocalStorage.inl
index fe2d02d0..2b920d0f 100644
--- a/Private/KernelKit/ThreadLocalStorage.inl
+++ b/Private/KernelKit/ThreadLocalStorage.inl
@@ -12,7 +12,7 @@
template <typename T>
inline T* tls_new_ptr(void) {
- using namespace HCore;
+ using namespace NewOS;
MUST_PASS(ProcessScheduler::Shared().Leak().GetCurrent());
@@ -27,7 +27,7 @@ template <typename T>
inline bool tls_delete_ptr(T* ptr) {
if (!ptr) return false;
- using namespace HCore;
+ using namespace NewOS;
MUST_PASS(ProcessScheduler::Shared().Leak().GetCurrent());
@@ -42,7 +42,7 @@ T* tls_new_class(Args&&... args) {
T* ptr = tls_new_ptr<T>();
if (ptr) {
- *ptr = T(HCore::forward(args)...);
+ *ptr = T(NewOS::forward(args)...);
return ptr;
}
diff --git a/Private/KernelKit/Timer.hpp b/Private/KernelKit/Timer.hpp
index f60f6e0e..87cb915d 100644
--- a/Private/KernelKit/Timer.hpp
+++ b/Private/KernelKit/Timer.hpp
@@ -11,7 +11,7 @@
#include <NewKit/ErrorID.hpp>
-namespace HCore
+namespace NewOS
{
class HardwareTimer;
class HardwareTimerInterface;
@@ -62,4 +62,4 @@ inline Int64 Milliseconds(Int64 time)
return 1000 / Seconds(time);
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/KernelKit/UserHeap.hpp b/Private/KernelKit/UserHeap.hpp
index d66eb356..728fcd80 100644
--- a/Private/KernelKit/UserHeap.hpp
+++ b/Private/KernelKit/UserHeap.hpp
@@ -20,7 +20,7 @@
#define kUserHeapMaxSz (4096)
#define kUserHeapMag (0x5500A1)
-namespace HCore {
+namespace NewOS {
typedef enum {
kUserHeapHypervisor = 0x2,
kUserHeapShared = 0x4,
@@ -37,4 +37,4 @@ VoidPtr rt_new_heap(Int32 flags);
/// @param pointer The process heap pointer.
/// @return
Int32 rt_free_heap(voidPtr pointer);
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NetworkKit/IP.hpp b/Private/NetworkKit/IP.hpp
index d2d73b17..3d7119da 100644
--- a/Private/NetworkKit/IP.hpp
+++ b/Private/NetworkKit/IP.hpp
@@ -11,7 +11,7 @@
#include <NewKit/Ref.hpp>
#include <NewKit/String.hpp>
-namespace HCore {
+namespace NewOS {
class RawIPAddress6;
class RawIPAddress;
class IPFactory;
@@ -73,4 +73,4 @@ class IPFactory final {
static ErrorOr<StringView> ToStringView(Ref<RawIPAddress> ipv4);
static bool IpCheckVersion4(const char *ip);
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NetworkKit/MAC.hxx b/Private/NetworkKit/MAC.hxx
index fb11ae2b..59f4b31f 100644
--- a/Private/NetworkKit/MAC.hxx
+++ b/Private/NetworkKit/MAC.hxx
@@ -10,7 +10,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/String.hpp>
-namespace HCore {
+namespace NewOS {
class MacAddressGetter;
/// \brief This retrieves the MAC address of the device.
@@ -24,4 +24,4 @@ class MacAddressGetter final {
Array<WideChar, 12>& AsBytes();
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NetworkKit/NetworkDevice.hpp b/Private/NetworkKit/NetworkDevice.hpp
index d85cb939..24106478 100644
--- a/Private/NetworkKit/NetworkDevice.hpp
+++ b/Private/NetworkKit/NetworkDevice.hpp
@@ -10,7 +10,7 @@
#include <KernelKit/DeviceManager.hpp>
#include <NetworkKit/IP.hpp>
-namespace HCore {
+namespace NewOS {
struct NetworkDeviceCommand;
class NetworkDevice;
@@ -55,7 +55,7 @@ using PPPNetworkDevice = NetworkDevice;
/// @brief HPC device.
using HPCNetworkDevice = NetworkDevice;
-} // namespace HCore
+} // namespace NewOS
#include <NetworkKit/NetworkDevice.inl>
diff --git a/Private/NetworkKit/NetworkDevice.inl b/Private/NetworkKit/NetworkDevice.inl
index 0780a0b0..30b65f55 100644
--- a/Private/NetworkKit/NetworkDevice.inl
+++ b/Private/NetworkKit/NetworkDevice.inl
@@ -8,7 +8,7 @@
Dtor and ctors.
*/
-namespace HCore {
+namespace NewOS {
NetworkDevice::NetworkDevice(void (*out)(NetworkDeviceCommand),
void (*in)(NetworkDeviceCommand),
void (*on_cleanup)(void))
@@ -24,4 +24,4 @@ NetworkDevice::~NetworkDevice() {
kcout << "NK: NetworkDevice cleanup.\r\n";
if (fCleanup) fCleanup();
}
-} // namespace HCore \ No newline at end of file
+} // namespace NewOS \ No newline at end of file
diff --git a/Private/NewBoot/BootKit/Arch/ATA.hxx b/Private/NewBoot/BootKit/Arch/ATA.hxx
index 8e0a15eb..4defc0aa 100644
--- a/Private/NewBoot/BootKit/Arch/ATA.hxx
+++ b/Private/NewBoot/BootKit/Arch/ATA.hxx
@@ -8,7 +8,7 @@
#include <Builtins/ATA/Defines.hxx>
-using namespace HCore;
+using namespace NewOS;
class BDeviceATA final {
public:
diff --git a/Private/NewBoot/BootKit/Arch/SATA.hxx b/Private/NewBoot/BootKit/Arch/SATA.hxx
index dc48c3ea..8bd8f2cb 100644
--- a/Private/NewBoot/BootKit/Arch/SATA.hxx
+++ b/Private/NewBoot/BootKit/Arch/SATA.hxx
@@ -17,17 +17,17 @@ class BDeviceSATA final {
HCORE_COPY_DEFAULT(BDeviceSATA);
struct SATATrait final {
- HCore::SizeT mBase{1024};
- HCore::Boolean mErr{false};
- HCore::Boolean mDetected{false};
+ NewOS::SizeT mBase{1024};
+ NewOS::Boolean mErr{false};
+ NewOS::Boolean mDetected{false};
operator bool() { return !this->mErr; }
};
operator bool() { return this->Leak().mDetected; }
- BDeviceSATA& Read(HCore::WideChar* Buf, const HCore::SizeT& SecCount);
- BDeviceSATA& Write(HCore::WideChar* Buf, const HCore::SizeT& SecCount);
+ BDeviceSATA& Read(NewOS::WideChar* Buf, const NewOS::SizeT& SecCount);
+ BDeviceSATA& Write(NewOS::WideChar* Buf, const NewOS::SizeT& SecCount);
SATATrait& Leak();
diff --git a/Private/NewBoot/BootKit/BootKit.hxx b/Private/NewBoot/BootKit/BootKit.hxx
index 75934ed2..a0e8309c 100644
--- a/Private/NewBoot/BootKit/BootKit.hxx
+++ b/Private/NewBoot/BootKit/BootKit.hxx
@@ -22,7 +22,7 @@ class BVersionString;
#include <NewKit/Defines.hpp>
#include <FirmwareKit/EPM.hxx>
-using namespace HCore;
+using namespace NewOS;
typedef Char *PEFImagePtr;
typedef Char *PEImagePtr;
@@ -57,18 +57,18 @@ class BTextWriter final {
BTextWriter(const BTextWriter &) = default;
};
-HCore::SizeT BCopyMem(CharacterTypeUTF16 *dest, CharacterTypeUTF16 *src,
- const HCore::SizeT len);
+NewOS::SizeT BCopyMem(CharacterTypeUTF16 *dest, CharacterTypeUTF16 *src,
+ const NewOS::SizeT len);
-HCore::SizeT BSetMem(CharacterTypeUTF8 *src, const CharacterTypeUTF8 byte,
- const HCore::SizeT len);
+NewOS::SizeT BSetMem(CharacterTypeUTF8 *src, const CharacterTypeUTF8 byte,
+ const NewOS::SizeT len);
/// String length functions.
-HCore::SizeT BStrLen(const CharacterTypeUTF16 *ptr);
+NewOS::SizeT BStrLen(const CharacterTypeUTF16 *ptr);
-HCore::SizeT BSetMem(CharacterTypeUTF16 *src, const CharacterTypeUTF16 byte,
- const HCore::SizeT len);
+NewOS::SizeT BSetMem(CharacterTypeUTF16 *src, const CharacterTypeUTF16 byte,
+ const NewOS::SizeT len);
/**
* @brief BootKit File Reader class
diff --git a/Private/NewBoot/Source/HEL/AMD64/BootEPM.cxx b/Private/NewBoot/Source/HEL/AMD64/BootEPM.cxx
index b8df12a0..da8e6107 100644
--- a/Private/NewBoot/Source/HEL/AMD64/BootEPM.cxx
+++ b/Private/NewBoot/Source/HEL/AMD64/BootEPM.cxx
@@ -36,7 +36,7 @@ EXTERN_C Boolean boot_write_newfs_partition(const Char* namePart, SizeT namePart
BootBlockType* bootBlock = (BootBlockType*)buf;
- bootBlock->Version = kEPMHCore;
+ bootBlock->Version = kEPMNewOS;
bootBlock->NumBlocks = kEPMMaxBlks;
for (SizeT i = 0; i < kEPMNameLength; i++) {
@@ -63,7 +63,7 @@ EXTERN_C Boolean boot_write_newfs_partition(const Char* namePart, SizeT namePart
partBlock->Fs[i] = fsName[i];
}
- partBlock->Magic = kEPMHCore;
+ partBlock->Magic = kEPMNewOS;
char* partName = "System HD";
int partNameLength = 10;
@@ -84,7 +84,7 @@ EXTERN_C Boolean boot_write_newfs_partition(const Char* namePart, SizeT namePart
swapBlock->Fs[i] = fsName[i];
}
- swapBlock->Magic = kEPMHCore;
+ swapBlock->Magic = kEPMNewOS;
partName = "Swap HD";
partNameLength = 8;
diff --git a/Private/NewBoot/Source/HEL/AMD64/BootString.cxx b/Private/NewBoot/Source/HEL/AMD64/BootString.cxx
index 52633fe2..1c6b528e 100644
--- a/Private/NewBoot/Source/HEL/AMD64/BootString.cxx
+++ b/Private/NewBoot/Source/HEL/AMD64/BootString.cxx
@@ -17,8 +17,8 @@
/////////////////////////////////////////////////////////////////////////////////////////////////////////
-HCore::SizeT BCopyMem(CharacterTypeUTF16 *dest, CharacterTypeUTF16 *src,
- const HCore::SizeT len) {
+NewOS::SizeT BCopyMem(CharacterTypeUTF16 *dest, CharacterTypeUTF16 *src,
+ const NewOS::SizeT len) {
if (!dest || !src) return 0;
SizeT index = 0UL;
@@ -29,10 +29,10 @@ HCore::SizeT BCopyMem(CharacterTypeUTF16 *dest, CharacterTypeUTF16 *src,
return index;
}
-HCore::SizeT BStrLen(const CharacterTypeUTF16 *ptr) {
+NewOS::SizeT BStrLen(const CharacterTypeUTF16 *ptr) {
if (!ptr) return 0;
- HCore::SizeT cnt = 0;
+ NewOS::SizeT cnt = 0;
while (*ptr != (CharacterTypeUTF16)0) {
++ptr;
@@ -42,11 +42,11 @@ HCore::SizeT BStrLen(const CharacterTypeUTF16 *ptr) {
return cnt;
}
-HCore::SizeT BSetMem(CharacterTypeUTF16 *src, const CharacterTypeUTF16 byte,
- const HCore::SizeT len) {
+NewOS::SizeT BSetMem(CharacterTypeUTF16 *src, const CharacterTypeUTF16 byte,
+ const NewOS::SizeT len) {
if (!src) return 0;
- HCore::SizeT cnt = 0UL;
+ NewOS::SizeT cnt = 0UL;
while (*src != 0) {
if (cnt > len) break;
@@ -60,11 +60,11 @@ HCore::SizeT BSetMem(CharacterTypeUTF16 *src, const CharacterTypeUTF16 byte,
return cnt;
}
-HCore::SizeT BSetMem(CharacterTypeUTF8 *src, const CharacterTypeUTF8 byte,
- const HCore::SizeT len) {
+NewOS::SizeT BSetMem(CharacterTypeUTF8 *src, const CharacterTypeUTF8 byte,
+ const NewOS::SizeT len) {
if (!src) return 0;
- HCore::SizeT cnt = 0UL;
+ NewOS::SizeT cnt = 0UL;
while (*src != 0) {
if (cnt > len) break;
diff --git a/Private/NewBoot/Source/makefile b/Private/NewBoot/Source/makefile
index 35c473ec..9e2dbca6 100644
--- a/Private/NewBoot/Source/makefile
+++ b/Private/NewBoot/Source/makefile
@@ -26,7 +26,7 @@ REM=rm
REM_FLAG=-f
FLAG_ASM=-f win64
-FLAG_GNU=-fshort-wchar -mgeneral-regs-only -mno-red-zone -D__KERNEL__ -DEFI_FUNCTION_WRAPPER -I../ -I../../ -I./ -c -ffreestanding -fno-rtti -fno-exceptions -std=c++20 -D__HAVE_HCORE_APIS__ -D__HCORE__ -D__BOOTLOADER__ -I./
+FLAG_GNU=-fshort-wchar -mgeneral-regs-only -mno-red-zone -D__KERNEL__ -DEFI_FUNCTION_WRAPPER -I../ -I../../ -I./ -c -ffreestanding -fno-rtti -fno-exceptions -std=c++20 -D__HAVE_MAHROUSS_APIS__ -D__MAHROUSS__ -D__BOOTLOADER__ -I./
.PHONY: invalid-recipe
invalid-recipe:
diff --git a/Private/NewKit/Array.hpp b/Private/NewKit/Array.hpp
index c6153421..a892f1a7 100644
--- a/Private/NewKit/Array.hpp
+++ b/Private/NewKit/Array.hpp
@@ -9,7 +9,7 @@
#include <NewKit/ErrorOr.hpp>
#include <NewKit/Defines.hpp>
-namespace HCore
+namespace NewOS
{
template <typename T, Size N>
class Array final
@@ -67,4 +67,4 @@ private:
T m_Array[N];
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/ArrayList.hpp b/Private/NewKit/ArrayList.hpp
index 9a1c7e9c..ef6889ea 100644
--- a/Private/NewKit/ArrayList.hpp
+++ b/Private/NewKit/ArrayList.hpp
@@ -8,7 +8,7 @@
#include <NewKit/Defines.hpp>
-namespace HCore
+namespace NewOS
{
template <typename T>
class ArrayList final
@@ -54,4 +54,4 @@ namespace HCore
{
return ArrayList<ValueType>{val};
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/Atom.hpp b/Private/NewKit/Atom.hpp
index 8ace1b80..34cbea51 100644
--- a/Private/NewKit/Atom.hpp
+++ b/Private/NewKit/Atom.hpp
@@ -7,7 +7,7 @@
#include <NewKit/Defines.hpp>
-namespace HCore
+namespace NewOS
{
template <typename T> class Atom final
{
@@ -42,4 +42,4 @@ template <typename T> class Atom final
private:
T m_ArrayOfAtoms;
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/Crc32.hpp b/Private/NewKit/Crc32.hpp
index 7e9ce2af..0dccd4d8 100644
--- a/Private/NewKit/Crc32.hpp
+++ b/Private/NewKit/Crc32.hpp
@@ -1,7 +1,7 @@
/*
* ========================================================
*
- * HCore Date Added: 13/02/2023
+ * NewOS Date Added: 13/02/2023
* Copyright Mahrouss Logic, all rights reserved.
*
* ========================================================
@@ -14,8 +14,8 @@
#define kCrcCnt (256)
-namespace HCore {
+namespace NewOS {
UInt ke_calculate_crc32(const Char* crc, UInt len) noexcept;
-} // namespace HCore
+} // namespace NewOS
#endif // !__CRC32_H__
diff --git a/Private/NewKit/Defines.hpp b/Private/NewKit/Defines.hpp
index af87e377..e2951174 100644
--- a/Private/NewKit/Defines.hpp
+++ b/Private/NewKit/Defines.hpp
@@ -22,7 +22,7 @@
#endif
#endif
-namespace HCore {
+namespace NewOS {
using voidPtr = void *;
using VoidPtr = void *;
using nullPtr = decltype(nullptr);
@@ -119,17 +119,17 @@ public:
}
};
-} // namespace HCore
+} // namespace NewOS
#define DEDUCE_ENDIAN(address, value) \
- (((reinterpret_cast<HCore::Char *>(address)[0]) == (value)) \
- ? (HCore::Endian::kEndianBig) \
- : (HCore::Endian::kEndianLittle))
+ (((reinterpret_cast<NewOS::Char *>(address)[0]) == (value)) \
+ ? (NewOS::Endian::kEndianBig) \
+ : (NewOS::Endian::kEndianLittle))
#define Yes (true)
#define No (false)
-#define VoidStar HCore::voidPtr
+#define VoidStar NewOS::voidPtr
#ifdef INIT
#undef INIT
diff --git a/Private/NewKit/ErrorOr.hpp b/Private/NewKit/ErrorOr.hpp
index 8847c1e6..6d85a943 100644
--- a/Private/NewKit/ErrorOr.hpp
+++ b/Private/NewKit/ErrorOr.hpp
@@ -1,7 +1,7 @@
/*
* ========================================================
*
-* HCore
+* NewOS
* Copyright Mahrouss Logic, all rights reserved.
*
* ========================================================
@@ -12,7 +12,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore
+namespace NewOS
{
using ErrorT = UInt;
@@ -65,4 +65,4 @@ template <typename T> class ErrorOr final
using ErrorOrAny = ErrorOr<voidPtr>;
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/Function.hpp b/Private/NewKit/Function.hpp
index 20d63f80..63bc31dc 100644
--- a/Private/NewKit/Function.hpp
+++ b/Private/NewKit/Function.hpp
@@ -3,7 +3,7 @@
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
template <typename T, typename... Args>
class Function final {
public:
@@ -34,6 +34,6 @@ class Function final {
private:
T (*m_Fn)(Args... args);
};
-} // namespace HCore
+} // namespace NewOS
#endif // !_INC_FUNCTION_HPP__
diff --git a/Private/NewKit/Json.hpp b/Private/NewKit/Json.hpp
index 373b0772..6be7430d 100644
--- a/Private/NewKit/Json.hpp
+++ b/Private/NewKit/Json.hpp
@@ -15,11 +15,11 @@
#include <NewKit/String.hpp>
#include <NewKit/Utils.hpp>
-namespace HCore {
+namespace NewOS {
/// @brief Json value class
class JsonType final {
public:
- explicit JsonType() : HCore::JsonType(1, 1) {}
+ explicit JsonType() : NewOS::JsonType(1, 1) {}
explicit JsonType(SizeT lhsLen, SizeT rhsLen)
: fKey(lhsLen), fValue(rhsLen) {}
@@ -89,4 +89,4 @@ struct JsonStreamTrait final {
};
using JsonStream = Stream<JsonStreamTrait, JsonType>;
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/KernelCheck.hpp b/Private/NewKit/KernelCheck.hpp
index 77dc558a..c65390ad 100644
--- a/Private/NewKit/KernelCheck.hpp
+++ b/Private/NewKit/KernelCheck.hpp
@@ -9,13 +9,13 @@
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
void ke_runtime_check(bool bExpression, const char *file, const char *line);
}
#define MUST_PASS_COMPILER(EXPR, MSG) static_assert(EXPR, MSG)
#define __MUST_PASS(EXPR, FILE, LINE) \
- HCore::ke_runtime_check(EXPR, FILE, STRINGIFY(LINE))
+ NewOS::ke_runtime_check(EXPR, FILE, STRINGIFY(LINE))
#define MUST_PASS(EXPR) __MUST_PASS(EXPR, __FILE__, __LINE__)
#define assert(EXPR) MUST_PASS(EXPR, RUNTIME_CHECK_EXPRESSION)
@@ -36,7 +36,7 @@ enum RUNTIME_CHECK {
RUNTIME_CHECK_COUNT,
};
-namespace HCore {
+namespace NewOS {
class DumpManager final {
public:
static void Dump(void) {
@@ -45,7 +45,7 @@ class DumpManager final {
};
void ke_stop(const Int &id);
-} // namespace HCore
+} // namespace NewOS
#ifdef TRY
#undef TRY
diff --git a/Private/NewKit/Macros.hpp b/Private/NewKit/Macros.hpp
index c6c4f530..62780068 100644
--- a/Private/NewKit/Macros.hpp
+++ b/Private/NewKit/Macros.hpp
@@ -25,7 +25,7 @@
#ifndef ARRAY_SIZE
#define ARRAY_SIZE(a) \
(((sizeof(a) / sizeof(*(a))) / \
- (static_cast<HCore::Size>(!(sizeof(a) % sizeof(*(a)))))))
+ (static_cast<NewOS::Size>(!(sizeof(a) % sizeof(*(a)))))))
#endif
#ifndef ALIGN
@@ -36,9 +36,9 @@
#define ATTRIBUTE(X) __attribute__((X))
#endif // #ifndef ATTRIBUTE
-#ifndef __HCORE__
-#define __HCORE__ (202401)
-#endif // !__HCORE__
+#ifndef __MAHROUSS__
+#define __MAHROUSS__ (202401)
+#endif // !__MAHROUSS__
#ifndef EXTERN_C
#define EXTERN_C extern "C"
diff --git a/Private/NewKit/MutableArray.hpp b/Private/NewKit/MutableArray.hpp
index 24bb06d4..1be94548 100644
--- a/Private/NewKit/MutableArray.hpp
+++ b/Private/NewKit/MutableArray.hpp
@@ -44,7 +44,7 @@
// FIXME: this is a shitty algorithm, which is consumer hungry.
// Remove and occurences of that, and remove that class.
-namespace HCore
+namespace NewOS
{
template <typename T> class MutableArray;
@@ -142,7 +142,7 @@ template <typename T, T _PlaceHolderValue> class NullableMutableArray
MutableLinkedList<T> *m_FirstNode{nullptr};
/* Number of nodes inside of this dynamic array. */
- HCore::SizeT m_NodeCount{0};
+ NewOS::SizeT m_NodeCount{0};
private:
// don't remove that
@@ -217,6 +217,6 @@ class MutableArray : public NullableMutableArray<voidPtr, nullptr>
MutableLinkedList<T> *m_FirstNode{nullptr};
/* Number of nodes inside of this dynamic array. */
- HCore::SizeT m_NodeCount{0};
+ NewOS::SizeT m_NodeCount{0};
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/OwnPtr.hpp b/Private/NewKit/OwnPtr.hpp
index 4c1f295b..e6d006ed 100644
--- a/Private/NewKit/OwnPtr.hpp
+++ b/Private/NewKit/OwnPtr.hpp
@@ -11,7 +11,7 @@
#include <NewKit/KernelCheck.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore {
+namespace NewOS {
template <typename T>
class OwnPtr;
@@ -64,4 +64,4 @@ OwnPtr<T> make_ptr(Args... args) {
return ret;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/PageAllocator.hpp b/Private/NewKit/PageAllocator.hpp
index 2b761844..0b691a64 100644
--- a/Private/NewKit/PageAllocator.hpp
+++ b/Private/NewKit/PageAllocator.hpp
@@ -10,7 +10,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/PageManager.hpp>
-namespace HCore {
+namespace NewOS {
namespace Detail {
VoidPtr create_page_wrapper(Boolean rw, Boolean user);
void exec_disable(UIntPtr addr);
@@ -18,4 +18,4 @@ bool page_disable(UIntPtr addr);
} // namespace Detail
// TODO: SwapVirtualMemoryDevice class!
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/PageManager.hpp b/Private/NewKit/PageManager.hpp
index a167c0f9..9aba5a6c 100644
--- a/Private/NewKit/PageManager.hpp
+++ b/Private/NewKit/PageManager.hpp
@@ -17,7 +17,7 @@
#define kBadAddress (0)
#endif // #ifndef kBadAddress
-namespace HCore {
+namespace NewOS {
class PageManager;
class PTEWrapper final {
@@ -76,4 +76,4 @@ struct PageManager final {
friend PTEWrapper;
friend class Pmm;
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/Pair.hpp b/Private/NewKit/Pair.hpp
index 6c87da3d..1522caf3 100644
--- a/Private/NewKit/Pair.hpp
+++ b/Private/NewKit/Pair.hpp
@@ -8,7 +8,7 @@
#include <NewKit/Defines.hpp>
-namespace HCore
+namespace NewOS
{
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/Pmm.hpp b/Private/NewKit/Pmm.hpp
index e8b4f05f..ed43a03c 100644
--- a/Private/NewKit/Pmm.hpp
+++ b/Private/NewKit/Pmm.hpp
@@ -10,7 +10,7 @@
#include <NewKit/PageManager.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore {
+namespace NewOS {
class Pmm;
class PTEWrapper;
@@ -36,4 +36,4 @@ class Pmm final {
private:
Ref<PageManager> m_PageManager;
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/Ref.hpp b/Private/NewKit/Ref.hpp
index 5ae7ea80..4327081b 100644
--- a/Private/NewKit/Ref.hpp
+++ b/Private/NewKit/Ref.hpp
@@ -10,7 +10,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/KernelCheck.hpp>
-namespace HCore {
+namespace NewOS {
template <typename T>
class Ref final {
public:
@@ -60,4 +60,4 @@ class NonNullRef final {
private:
Ref<T> m_Ref{nullptr};
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/Stream.hpp b/Private/NewKit/Stream.hpp
index c344808f..30e60939 100644
--- a/Private/NewKit/Stream.hpp
+++ b/Private/NewKit/Stream.hpp
@@ -10,7 +10,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore
+namespace NewOS
{
template <typename StreamTrait, typename Kind>
class Stream final
@@ -55,4 +55,4 @@ namespace HCore
Ref<Kind> m_Kind;
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/String.hpp b/Private/NewKit/String.hpp
index 3694f16c..1806c32a 100644
--- a/Private/NewKit/String.hpp
+++ b/Private/NewKit/String.hpp
@@ -10,7 +10,7 @@
#include <NewKit/ErrorOr.hpp>
#include <NewKit/KernelCheck.hpp>
-namespace HCore {
+namespace NewOS {
class StringView final {
public:
explicit StringView() = default;
@@ -60,4 +60,4 @@ struct StringBuilder final {
static const char *Format(const char *fmt, const char *from);
static bool Equals(const char *lhs, const char *rhs);
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/Utils.hpp b/Private/NewKit/Utils.hpp
index 5ef26157..67ecaf22 100644
--- a/Private/NewKit/Utils.hpp
+++ b/Private/NewKit/Utils.hpp
@@ -9,7 +9,7 @@
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
Int rt_copy_memory(const voidPtr src, voidPtr dst, Size len);
Int rt_move_memory(const voidPtr src, voidPtr dst, Size len);
voidPtr rt_set_memory(voidPtr dst, Char val, Size len);
@@ -25,4 +25,4 @@ Int rt_to_uppercase(Int c);
Int rt_to_lower(Int c);
voidPtr rt_string_in_string(const char *in, const char *needle);
char *rt_string_from_char(char *str, const char chr);
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/NewKit/Variant.hpp b/Private/NewKit/Variant.hpp
index 77c9726f..109acbbe 100644
--- a/Private/NewKit/Variant.hpp
+++ b/Private/NewKit/Variant.hpp
@@ -9,7 +9,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/String.hpp>
-namespace HCore {
+namespace NewOS {
class Variant final {
public:
enum class VariantKind { kString, kPointer, kUndefined };
@@ -36,4 +36,4 @@ class Variant final {
voidPtr m_Ptr{nullptr};
VariantKind m_Kind{VariantKind::kUndefined};
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/ObjectKit/ObjectKit.hxx b/Private/ObjectKit/ObjectKit.hxx
index 0a388156..5569ac51 100644
--- a/Private/ObjectKit/ObjectKit.hxx
+++ b/Private/ObjectKit/ObjectKit.hxx
@@ -24,13 +24,13 @@ enum {
/// \brief Object handle.
/// \author Amlal El Mahrouss
typedef struct Object final {
- HCore::Char ObjectName[255];
- HCore::Int32 ObjectType;
- HCore::Char ObjectNamespace[255];
+ NewOS::Char ObjectName[255];
+ NewOS::Int32 ObjectType;
+ NewOS::Char ObjectNamespace[255];
- HCore::Void(*Release)(struct Object* Self);
- HCore::IntPtr(*Invoke)(struct Object* Self, HCore::Int32 Sel, ...);
- HCore::Void(*Query)(struct Object* Self, HCore::VoidPtr* Dst, HCore::SizeT SzDst, HCore::XRN::GUIDSequence GuidOf);
+ NewOS::Void(*Release)(struct Object* Self);
+ NewOS::IntPtr(*Invoke)(struct Object* Self, NewOS::Int32 Sel, ...);
+ NewOS::Void(*Query)(struct Object* Self, NewOS::VoidPtr* Dst, NewOS::SizeT SzDst, NewOS::XRN::GUIDSequence GuidOf);
} *ObjectRef;
#define object_cast reinterpret_cast<ObjectRef>
diff --git a/Private/Root/System/FileExplorerHome.html b/Private/Root/System/FileExplorerHome.html
index 9a7ab947..f37e6d64 100644
--- a/Private/Root/System/FileExplorerHome.html
+++ b/Private/Root/System/FileExplorerHome.html
@@ -3,7 +3,7 @@
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>HCore WebTraveler</title>
+ <title>NewOS WebTraveler</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.4.1/dist/css/bootstrap.min.css" integrity="sha384-Vkoo8x4CGsO3+Hhxv8T/Q5PaXtkKtu6ug5TOeNV6gBiFeWPGFN9MuhOf23Q9Ifjh" crossorigin="anonymous">
@@ -15,7 +15,7 @@
<nav class="navbar navbar-expand-lg bg-body-tertiary">
<div class="container-fluid">
- <a class="navbar-brand" href="#">HCore</a>
+ <a class="navbar-brand" href="#">NewOS</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
diff --git a/Private/Source/Crc32.cxx b/Private/Source/Crc32.cxx
index eab12c37..27cbae7f 100644
--- a/Private/Source/Crc32.cxx
+++ b/Private/Source/Crc32.cxx
@@ -9,7 +9,7 @@
// @file CRC32.cpp
// @brief Check sequence implementation.
-namespace HCore {
+namespace NewOS {
/// @brief The CRC32 table.
UInt kCrcTbl[kCrcCnt] = {
0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, 0x706af48f,
@@ -68,4 +68,4 @@ UInt ke_calculate_crc32(const Char *p, UInt len) noexcept {
// return (~crc); also works, does the same thing.
return (crc ^ 0xffffffff);
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/CxxAbi.cxx b/Private/Source/CxxAbi.cxx
index 730e9f81..41df73fd 100644
--- a/Private/Source/CxxAbi.cxx
+++ b/Private/Source/CxxAbi.cxx
@@ -13,7 +13,7 @@ atexit_func_entry_t __atexit_funcs[kDSOMaxObjects];
uarch_t __atexit_func_count;
extern "C" void __cxa_pure_virtual() {
- HCore::kcout << "NewKernel.exe: C++ placeholder method.\n";
+ NewOS::kcout << "NewKernel.exe: C++ placeholder method.\n";
}
extern "C" void ___chkstk_ms() {
diff --git a/Private/Source/DriveManager.cxx b/Private/Source/DriveManager.cxx
index 00e1d94d..26cab611 100644
--- a/Private/Source/DriveManager.cxx
+++ b/Private/Source/DriveManager.cxx
@@ -7,4 +7,4 @@
#include <KernelKit/DebugOutput.hpp>
#include <KernelKit/DriveManager.hxx>
-namespace HCore {} // namespace HCore
+namespace NewOS {} // namespace NewOS
diff --git a/Private/Source/FileManager.cxx b/Private/Source/FileManager.cxx
index 4d3c9417..bbe7d30b 100644
--- a/Private/Source/FileManager.cxx
+++ b/Private/Source/FileManager.cxx
@@ -9,9 +9,9 @@
#include <NewKit/Utils.hpp>
/// BUGS: 0
-//! @brief File manager for HCore.
+//! @brief File manager for NewOS.
-namespace HCore {
+namespace NewOS {
static FilesystemManagerInterface* kMounted = nullptr;
/// @brief FilesystemManager getter.
@@ -42,4 +42,4 @@ bool FilesystemManagerInterface::Mount(FilesystemManagerInterface* mountPtr) {
return false;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/Framebuffer.cxx b/Private/Source/Framebuffer.cxx
index 9c964a3c..2682d165 100644
--- a/Private/Source/Framebuffer.cxx
+++ b/Private/Source/Framebuffer.cxx
@@ -19,7 +19,7 @@
*
*/
-using namespace HCore;
+using namespace NewOS;
/**
* @brief Get Pixel at
@@ -59,9 +59,9 @@ Ref<FramebufferContext *> &Framebuffer::Leak() {
Framebuffer &Framebuffer::DrawRect(SizeT width, SizeT height, SizeT x, SizeT y,
UInt32 color) {
- for (HCore::SizeT i = x; i < width + x; ++i) {
- for (HCore::SizeT u = y; u < height + y; ++u) {
- *(((volatile HCore::UInt32 *)(m_FrameBufferAddr.Leak()->m_Base +
+ for (NewOS::SizeT i = x; i < width + x; ++i) {
+ for (NewOS::SizeT u = y; u < height + y; ++u) {
+ *(((volatile NewOS::UInt32 *)(m_FrameBufferAddr.Leak()->m_Base +
4 * m_FrameBufferAddr.Leak()->m_Bpp * i +
4 * u))) = color;
}
@@ -71,7 +71,7 @@ Framebuffer &Framebuffer::DrawRect(SizeT width, SizeT height, SizeT x, SizeT y,
}
Framebuffer &Framebuffer::PutPixel(SizeT x, SizeT y, UInt32 color) {
- *(((volatile HCore::UInt32 *)(m_FrameBufferAddr.Leak()->m_Base +
+ *(((volatile NewOS::UInt32 *)(m_FrameBufferAddr.Leak()->m_Base +
4 * m_FrameBufferAddr.Leak()->m_Bpp * x +
4 * y))) = color;
diff --git a/Private/Source/GUIDWizard.cxx b/Private/Source/GUIDWizard.cxx
index 8befb071..90903979 100644
--- a/Private/Source/GUIDWizard.cxx
+++ b/Private/Source/GUIDWizard.cxx
@@ -17,7 +17,7 @@
// @brief Size of UUID.
#define kUUIDSize 37
-namespace HCore::XRN::Version1 {
+namespace NewOS::XRN::Version1 {
auto make_sequence(const ArrayList<UShort>& uuidSeq) -> Ref<GUIDSequence*> {
GUIDSequence* seq = new GUIDSequence();
MUST_PASS(seq);
@@ -55,4 +55,4 @@ auto try_guid_to_string(Ref<GUIDSequence*>& seq) -> ErrorOr<Ref<StringView>> {
return ErrorOr<Ref<StringView>>{-1};
}
-} // namespace HCore::XRN::Version1
+} // namespace NewOS::XRN::Version1
diff --git a/Private/Source/GUIDWrapper.cxx b/Private/Source/GUIDWrapper.cxx
index d7c592e5..72dbf225 100644
--- a/Private/Source/GUIDWrapper.cxx
+++ b/Private/Source/GUIDWrapper.cxx
@@ -6,4 +6,4 @@
#include <CFKit/GUIDWrapper.hpp>
-namespace HCore::XRN {}
+namespace NewOS::XRN {}
diff --git a/Private/Source/HError.cxx b/Private/Source/HError.cxx
index 95d38e57..d5995150 100644
--- a/Private/Source/HError.cxx
+++ b/Private/Source/HError.cxx
@@ -6,6 +6,6 @@
#include <KernelKit/HError.hpp>
-namespace HCore {
+namespace NewOS {
Boolean ke_bug_check(void) noexcept { return false; }
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/IndexableProperty.cxx b/Private/Source/IndexableProperty.cxx
index 3d5152bf..eec5f485 100644
--- a/Private/Source/IndexableProperty.cxx
+++ b/Private/Source/IndexableProperty.cxx
@@ -16,11 +16,11 @@
#define kMaxLenIndexer 256
-namespace HCore {
+namespace NewOS {
namespace Indexer {
IndexProperty& IndexableProperty::LeakProperty() noexcept { return fIndex; }
void IndexableProperty::AddFlag(Int16 flag) { fFlags |= flag; }
void IndexableProperty::RemoveFlag(Int16 flag) { fFlags &= flag; }
} // namespace Indexer
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/Json.cxx b/Private/Source/Json.cxx
index 26fe6c02..f91ad8b9 100644
--- a/Private/Source/Json.cxx
+++ b/Private/Source/Json.cxx
@@ -6,7 +6,7 @@
#include <NewKit/Json.hpp>
-using namespace HCore;
+using namespace NewOS;
/// @brief Undefined object, is null in length.
-INIT(HCore::JsonType::kUndefined, HCore::JsonType);
+INIT(NewOS::JsonType::kUndefined, NewOS::JsonType);
diff --git a/Private/Source/KernelCheck.cxx b/Private/Source/KernelCheck.cxx
index dcf8a06d..d290ca3d 100644
--- a/Private/Source/KernelCheck.cxx
+++ b/Private/Source/KernelCheck.cxx
@@ -11,16 +11,16 @@
extern "C" [[noreturn]] void ke_wait_for_debugger() {
while (true) {
- HCore::HAL::rt_cli();
- HCore::HAL::rt_halt();
+ NewOS::HAL::rt_cli();
+ NewOS::HAL::rt_halt();
}
}
/* Each error code is attributed with an ID, which will prompt a string onto the
* screen. Wait for debugger... */
-namespace HCore {
-void ke_stop(const HCore::Int &id) {
+namespace NewOS {
+void ke_stop(const NewOS::Int &id) {
kcout << "*** STOP *** \r\n";
kcout << "*** NewKernel.exe has trigerred a runtime stop. *** \r\n";
@@ -96,7 +96,7 @@ void ke_runtime_check(bool expr, const char *file, const char *line) {
#endif // __DEBUG__
- HCore::ke_stop(RUNTIME_CHECK_FAILED); // Runtime Check failed
+ NewOS::ke_stop(RUNTIME_CHECK_FAILED); // Runtime Check failed
}
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/KernelHeap.cxx b/Private/Source/KernelHeap.cxx
index 39648102..cdeabb24 100644
--- a/Private/Source/KernelHeap.cxx
+++ b/Private/Source/KernelHeap.cxx
@@ -15,7 +15,7 @@
#define kHeapMagic 0xD4D7
-namespace HCore {
+namespace NewOS {
STATIC SizeT kHeapCount = 0UL;
STATIC PageManager kHeapPageManager;
@@ -130,4 +130,4 @@ Boolean ke_protect_ke_heap(VoidPtr heapPtr) {
return false;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/Network/IP.cxx b/Private/Source/Network/IP.cxx
index c903dc95..04e5247d 100644
--- a/Private/Source/Network/IP.cxx
+++ b/Private/Source/Network/IP.cxx
@@ -7,7 +7,7 @@
#include <NetworkKit/IP.hpp>
#include <NewKit/Utils.hpp>
-namespace HCore {
+namespace NewOS {
char* RawIPAddress::Address() { return m_Addr; }
RawIPAddress::RawIPAddress(char bytes[4]) { rt_copy_memory(bytes, m_Addr, 4); }
@@ -91,4 +91,4 @@ bool IPFactory::IpCheckVersion4(const char* ip) {
return true;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/Network/NetworkDevice.cxx b/Private/Source/Network/NetworkDevice.cxx
index f43ef335..da0e2bb5 100644
--- a/Private/Source/Network/NetworkDevice.cxx
+++ b/Private/Source/Network/NetworkDevice.cxx
@@ -6,6 +6,6 @@
#include <NetworkKit/NetworkDevice.hpp>
-namespace HCore {
+namespace NewOS {
const char *NetworkDevice::Name() const { return "NetworkDevice"; }
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/New+Delete.cxx b/Private/Source/New+Delete.cxx
index d8901ce0..1178630b 100644
--- a/Private/Source/New+Delete.cxx
+++ b/Private/Source/New+Delete.cxx
@@ -10,25 +10,25 @@
void* operator new[](size_t sz) {
if (sz == 0) ++sz;
- return HCore::ke_new_ke_heap(sz, true, false);
+ return NewOS::ke_new_ke_heap(sz, true, false);
}
void* operator new(size_t sz) {
if (sz == 0) ++sz;
- return HCore::ke_new_ke_heap(sz, true, false);
+ return NewOS::ke_new_ke_heap(sz, true, false);
}
void operator delete[](void* ptr) {
if (ptr == nullptr) return;
- HCore::ke_delete_ke_heap(ptr);
+ NewOS::ke_delete_ke_heap(ptr);
}
void operator delete(void* ptr) {
if (ptr == nullptr) return;
- HCore::ke_delete_ke_heap(ptr);
+ NewOS::ke_delete_ke_heap(ptr);
}
void operator delete(void* ptr, size_t sz) {
@@ -36,5 +36,5 @@ void operator delete(void* ptr, size_t sz) {
HCORE_UNUSED(sz);
- HCore::ke_delete_ke_heap(ptr);
+ NewOS::ke_delete_ke_heap(ptr);
}
diff --git a/Private/Source/NewFS+FileManager.cxx b/Private/Source/NewFS+FileManager.cxx
index 5924385d..2b5abf27 100644
--- a/Private/Source/NewFS+FileManager.cxx
+++ b/Private/Source/NewFS+FileManager.cxx
@@ -11,7 +11,7 @@
/// @brief NewFS File manager.
/// BUGS: 0
-namespace HCore {
+namespace NewOS {
NewFilesystemManager::NewFilesystemManager() = default;
NewFilesystemManager::~NewFilesystemManager() = default;
@@ -42,6 +42,6 @@ const char* NewFilesystemHelper::Root() { return kNewFSRoot; }
const char* NewFilesystemHelper::UpDir() { return kNewFSUpDir; }
const char NewFilesystemHelper::Separator() { return kNewFSSeparator; }
-} // namespace HCore
+} // namespace NewOS
#endif // ifdef __FSKIT_NEWFS__
diff --git a/Private/Source/NewFS+IO.cxx b/Private/Source/NewFS+IO.cxx
index 1fd85dd8..502057e5 100644
--- a/Private/Source/NewFS+IO.cxx
+++ b/Private/Source/NewFS+IO.cxx
@@ -27,7 +27,7 @@
#define NEWFS_WRITE(DRV, TRAITS, MP) (*MP->DRV()) << TRAITS
#define NEWFS_READ(DRV, TRAITS, MP) (*MP->DRV()) >> TRAITS
-using namespace HCore;
+using namespace NewOS;
enum {
kHCFSSubDriveA,
diff --git a/Private/Source/NewFS+Journal.cxx b/Private/Source/NewFS+Journal.cxx
index b693e696..4eb2feb2 100644
--- a/Private/Source/NewFS+Journal.cxx
+++ b/Private/Source/NewFS+Journal.cxx
@@ -14,7 +14,7 @@
#define kNewFSOpLog (4)
-namespace HCore::Detail {
+namespace NewOS::Detail {
typedef Boolean (*NewFSRunnerType)(VoidPtr delegate);
/// @brief Journal thread class.
@@ -59,8 +59,8 @@ class NewFSJournalRunner final {
return false;
}
};
-} // namespace HCore::Detail
+} // namespace NewOS::Detail
-using namespace HCore;
+using namespace NewOS;
#endif // ifdef __FSKIT_NEWFS__
diff --git a/Private/Source/PEFCodeManager.cxx b/Private/Source/PEFCodeManager.cxx
index fc12d7a4..0ac703a3 100644
--- a/Private/Source/PEFCodeManager.cxx
+++ b/Private/Source/PEFCodeManager.cxx
@@ -15,7 +15,7 @@
#include <NewKit/OwnPtr.hpp>
#include <NewKit/String.hpp>
-namespace HCore {
+namespace NewOS {
namespace Detail {
UInt32 rt_get_pef_platform(void) noexcept {
#ifdef __32x0__
@@ -153,4 +153,4 @@ const char *PEFLoader::Path() { return fPath.Leak().CData(); }
const char *PEFLoader::Format() { return "PEF"; }
const char *PEFLoader::MIME() { return kPefApplicationMime; }
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/PEFSharedObjectRT.cxx b/Private/Source/PEFSharedObjectRT.cxx
index 871552d7..7dadbe1d 100644
--- a/Private/Source/PEFSharedObjectRT.cxx
+++ b/Private/Source/PEFSharedObjectRT.cxx
@@ -1,7 +1,7 @@
/*
* ========================================================
*
- * HCore
+ * NewOS
* Copyright Mahrouss Logic, all rights reserved.
*
* ========================================================
@@ -24,7 +24,7 @@
------------------------------------------- */
-using namespace HCore;
+using namespace NewOS;
/***********************************************************************************/
/// @file SharedObjectRT.cxx
diff --git a/Private/Source/PRDT.cxx b/Private/Source/PRDT.cxx
index cf3ceb64..f999dfd6 100644
--- a/Private/Source/PRDT.cxx
+++ b/Private/Source/PRDT.cxx
@@ -8,7 +8,7 @@
#include <NewKit/String.hpp>
#include <StorageKit/PRDT.hpp>
-namespace HCore {
+namespace NewOS {
PRDT::PRDT(const UIntPtr& physAddr) : m_PrdtAddr(physAddr) {
MUST_PASS(physAddr);
kcout << "PRDT::PRDT() {}\r\n";
@@ -29,4 +29,4 @@ PRDT& PRDT::operator=(const UIntPtr& prdtAddress) {
m_PrdtAddr = prdtAddress;
return *this;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/PageAllocator.cxx b/Private/Source/PageAllocator.cxx
index 209bb9ac..9b1e05f0 100644
--- a/Private/Source/PageAllocator.cxx
+++ b/Private/Source/PageAllocator.cxx
@@ -9,7 +9,7 @@
#include <NewKit/PageAllocator.hpp>
/// @brief Internal namespace, used internally by kernel.
-namespace HCore::Detail {
+namespace NewOS::Detail {
VoidPtr create_page_wrapper(Boolean rw, Boolean user) {
auto addr = HAL::hal_alloc_page(rw, user);
@@ -44,4 +44,4 @@ bool page_disable(UIntPtr VirtualAddr) {
return false;
}
-} // namespace HCore::Detail
+} // namespace NewOS::Detail
diff --git a/Private/Source/PageManager.cxx b/Private/Source/PageManager.cxx
index 67aa9b7f..4c4524cd 100644
--- a/Private/Source/PageManager.cxx
+++ b/Private/Source/PageManager.cxx
@@ -14,7 +14,7 @@
//! null deref will throw (Page Zero detected, aborting app!)
#define kProtectedRegionEnd (512)
-namespace HCore {
+namespace NewOS {
PTEWrapper::PTEWrapper(Boolean Rw, Boolean User, Boolean ExecDisable,
UIntPtr VirtAddr)
: m_Rw(Rw),
@@ -46,7 +46,7 @@ bool PTEWrapper::Reclaim() {
PTEWrapper PageManager::Request(Boolean Rw, Boolean User, Boolean ExecDisable) {
// Store PTE wrapper right after PTE.
- VoidPtr ptr = HCore::HAL::hal_alloc_page(Rw, User);
+ VoidPtr ptr = NewOS::HAL::hal_alloc_page(Rw, User);
return PTEWrapper{Rw, User, ExecDisable, (UIntPtr)ptr};
}
@@ -73,4 +73,4 @@ bool PTEWrapper::Access() { return m_Accessed; }
void PTEWrapper::NoExecute(const bool enable) { this->m_ExecDisable = enable; }
const bool &PTEWrapper::NoExecute() { return this->m_ExecDisable; }
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/PermissionSelector.cxx b/Private/Source/PermissionSelector.cxx
index 87680b06..47bd73f4 100644
--- a/Private/Source/PermissionSelector.cxx
+++ b/Private/Source/PermissionSelector.cxx
@@ -1,7 +1,7 @@
/*
* ========================================================
*
- * HCore
+ * NewOS
* Copyright Mahrouss Logic, all rights reserved.
*
* File: PermissionSelector.cpp
@@ -15,7 +15,7 @@
/// bugs 0
-namespace HCore {
+namespace NewOS {
PermissionSelector::PermissionSelector(const Int32 &sel)
: fRing((RingKind)sel) {
MUST_PASS(sel > 0);
@@ -35,4 +35,4 @@ bool PermissionSelector::operator!=(const PermissionSelector &lhs) {
}
const RingKind &PermissionSelector::Ring() noexcept { return this->fRing; }
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/Pmm.cxx b/Private/Source/Pmm.cxx
index 97614cfa..ba5f62e8 100644
--- a/Private/Source/Pmm.cxx
+++ b/Private/Source/Pmm.cxx
@@ -7,7 +7,7 @@
#include <KernelKit/DebugOutput.hpp>
#include <NewKit/Pmm.hpp>
-namespace HCore {
+namespace NewOS {
Pmm::Pmm() : m_PageManager() { kcout << "[PMM] Allocate PageMemoryManager"; }
Pmm::~Pmm() = default;
@@ -65,4 +65,4 @@ Boolean Pmm::ToggleShare(Ref<PTEWrapper> PageRef, Boolean Enable) {
return true;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/ProcessScheduler.cxx b/Private/Source/ProcessScheduler.cxx
index 54a4afe8..c29b4c89 100644
--- a/Private/Source/ProcessScheduler.cxx
+++ b/Private/Source/ProcessScheduler.cxx
@@ -20,7 +20,7 @@
/* This file handles the process scheduling.
/***********************************************************************************/
-namespace HCore {
+namespace NewOS {
/***********************************************************************************/
/// Exit Code stuff
/***********************************************************************************/
@@ -306,4 +306,4 @@ bool ProcessHelper::Switch(HAL::StackFrame *the_stack, const PID &new_pid) {
return false;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/ProcessTeam.cxx b/Private/Source/ProcessTeam.cxx
index 45cfb3bc..dbbcab24 100644
--- a/Private/Source/ProcessTeam.cxx
+++ b/Private/Source/ProcessTeam.cxx
@@ -11,7 +11,7 @@
#include <KernelKit/ProcessScheduler.hpp>
-namespace HCore {
+namespace NewOS {
/// @brief Process list array getter.
/// @return
MutableArray<Ref<ProcessHeader>>& ProcessTeam::AsArray() { return mProcessList; }
@@ -19,6 +19,6 @@ MutableArray<Ref<ProcessHeader>>& ProcessTeam::AsArray() { return mProcessList;
/// @brief Current process getter.
/// @return
Ref<ProcessHeader>& ProcessTeam::AsRef() { return mCurrentProcess; }
-} // namespace HCore
+} // namespace NewOS
// last rev 05-03-24
diff --git a/Private/Source/Property.cxx b/Private/Source/Property.cxx
index 9df9598c..81cf430a 100644
--- a/Private/Source/Property.cxx
+++ b/Private/Source/Property.cxx
@@ -6,10 +6,10 @@
#include <CFKit/Property.hpp>
-namespace HCore {
+namespace NewOS {
bool Property::StringEquals(StringView& name) {
return m_sName && this->m_sName == name;
}
const PropertyId& Property::GetPropertyById() { return m_Action; }
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/RuntimeMain.cxx b/Private/Source/RuntimeMain.cxx
index ffecaa18..3ae1d428 100644
--- a/Private/Source/RuntimeMain.cxx
+++ b/Private/Source/RuntimeMain.cxx
@@ -20,10 +20,10 @@
EXTERN_C void RuntimeMain(void) {
///! Mounts a NewFS block.
- HCore::NewFilesystemManager* newFS = new HCore::NewFilesystemManager();
- HCore::ke_protect_ke_heap(newFS);
+ NewOS::NewFilesystemManager* newFS = new NewOS::NewFilesystemManager();
+ NewOS::ke_protect_ke_heap(newFS);
- HCore::FilesystemManagerInterface::Mount(newFS);
+ NewOS::FilesystemManagerInterface::Mount(newFS);
///! we're done, unmount.
delete newFS;
diff --git a/Private/Source/SMPManager.cxx b/Private/Source/SMPManager.cxx
index b95eb68d..913bb44d 100644
--- a/Private/Source/SMPManager.cxx
+++ b/Private/Source/SMPManager.cxx
@@ -10,10 +10,10 @@
///! BUGS: 0
-///! @brief This file handles multi processing in HCore.
+///! @brief This file handles multi processing in NewOS.
///! @brief Multi processing is needed for multi-tasking operations.
-namespace HCore {
+namespace NewOS {
///! A HardwareThread class takes care of it's owned hardware thread.
///! It has a stack for it's core.
@@ -168,4 +168,4 @@ bool SMPManager::operator!() noexcept { return m_ThreadList.Empty(); }
/// @brief Returns the amount of core present.
/// @return the number of cores.
SizeT SMPManager::Count() noexcept { return m_ThreadList.Count(); }
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/Semaphore.cxx b/Private/Source/Semaphore.cxx
index 9767c8bb..df4e77ba 100644
--- a/Private/Source/Semaphore.cxx
+++ b/Private/Source/Semaphore.cxx
@@ -8,7 +8,7 @@
#include <KernelKit/Semaphore.hpp>
#include <KernelKit/Timer.hpp>
-namespace HCore {
+namespace NewOS {
bool Semaphore::Unlock() noexcept {
if (fLockingProcess) fLockingProcess = nullptr;
@@ -38,4 +38,4 @@ void Semaphore::Sync() noexcept {
while (fLockingProcess) {
}
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/Storage/AHCIDeviceInterface.cxx b/Private/Source/Storage/AHCIDeviceInterface.cxx
index 31fbce67..c6a4a4be 100644
--- a/Private/Source/Storage/AHCIDeviceInterface.cxx
+++ b/Private/Source/Storage/AHCIDeviceInterface.cxx
@@ -6,7 +6,7 @@
#include <StorageKit/AHCI.hpp>
-using namespace HCore;
+using namespace NewOS;
/// @brief Class constructor
/// @param Out Disk output
diff --git a/Private/Source/Storage/NVMEDeviceInterface.cxx b/Private/Source/Storage/NVMEDeviceInterface.cxx
index fc75604d..25f23272 100644
--- a/Private/Source/Storage/NVMEDeviceInterface.cxx
+++ b/Private/Source/Storage/NVMEDeviceInterface.cxx
@@ -6,6 +6,6 @@
#include <StorageKit/NVME.hpp>
-namespace HCore {
+namespace NewOS {
const char *NVMEDeviceInterface::Name() const { return ("NVMEDeviceInterface"); }
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/String.cxx b/Private/Source/String.cxx
index a27a3a37..a204777d 100644
--- a/Private/Source/String.cxx
+++ b/Private/Source/String.cxx
@@ -8,7 +8,7 @@
#include <NewKit/Utils.hpp>
#include <KernelKit/DebugOutput.hpp>
-namespace HCore {
+namespace NewOS {
Char *StringView::Data() { return m_Data; }
const Char *StringView::CData() { return m_Data; }
@@ -188,4 +188,4 @@ StringView &StringView::operator+=(const StringView &rhs) {
return *this;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/ThreadLocalStorage.cxx b/Private/Source/ThreadLocalStorage.cxx
index c75c1c5a..9ee6a4be 100644
--- a/Private/Source/ThreadLocalStorage.cxx
+++ b/Private/Source/ThreadLocalStorage.cxx
@@ -1,7 +1,7 @@
/*
* ========================================================
*
- * HCore
+ * NewOS
* Copyright Mahrouss Logic, all rights reserved.
*
* ========================================================
@@ -17,7 +17,7 @@
/// @brief TLS implementation in kernel.
/***********************************************************************************/
-using namespace HCore;
+using namespace NewOS;
/**
* Check for cookie inside TIB.
@@ -42,7 +42,7 @@ Boolean tls_check_tib(ThreadInformationBlock* tib) {
* @param ptr
* @return
*/
-EXTERN_C Void tls_check_syscall_impl(HCore::HAL::StackFramePtr stackPtr) noexcept {
+EXTERN_C Void tls_check_syscall_impl(NewOS::HAL::StackFramePtr stackPtr) noexcept {
ThreadInformationBlock* tib = (ThreadInformationBlock*)stackPtr->Gs;
if (!tls_check_tib(tib)) {
diff --git a/Private/Source/Timer.cxx b/Private/Source/Timer.cxx
index af9aea25..a35cc06f 100644
--- a/Private/Source/Timer.cxx
+++ b/Private/Source/Timer.cxx
@@ -8,7 +8,7 @@
// bugs = 0
-using namespace HCore;
+using namespace NewOS;
/// @brief Unimplemented as it is an interface.
Int32 HardwareTimerInterface::Wait() noexcept { return H_UNIMPLEMENTED; }
diff --git a/Private/Source/URL.cxx b/Private/Source/URL.cxx
index f4c17e43..004717ae 100644
--- a/Private/Source/URL.cxx
+++ b/Private/Source/URL.cxx
@@ -10,7 +10,7 @@
/// BUGS: 0
-namespace HCore {
+namespace NewOS {
Url::Url(StringView &strUrl) : m_urlView(strUrl, false) {}
Url::~Url() = default;
@@ -79,4 +79,4 @@ Ref<ErrorOr<StringView>> Url::Protocol() noexcept {
return Ref<ErrorOr<StringView>>(loc);
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/UserHeap.cxx b/Private/Source/UserHeap.cxx
index 4b172d11..dbec5728 100644
--- a/Private/Source/UserHeap.cxx
+++ b/Private/Source/UserHeap.cxx
@@ -16,7 +16,7 @@
/// KernelHeap.cxx
/// BUGS: 0
-namespace HCore {
+namespace NewOS {
/**
* @brief Process Heap Header
* @note Allocated per process, it denotes the user's heap.
@@ -209,4 +209,4 @@ Int32 rt_free_heap(VoidPtr ptr) {
return -1;
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/Source/Utils.cxx b/Private/Source/Utils.cxx
index d1b146f8..9072ead9 100644
--- a/Private/Source/Utils.cxx
+++ b/Private/Source/Utils.cxx
@@ -7,7 +7,7 @@
#include <NewKit/Utils.hpp>
#include <KernelKit/DebugOutput.hpp>
-namespace HCore {
+namespace NewOS {
Int rt_string_cmp(const Char *src, const Char *cmp, Size size) {
Int32 counter = 0;
@@ -166,12 +166,12 @@ char *rt_string_from_char(char *str, const char chr) {
return str;
}
-} // namespace HCore
+} // namespace NewOS
extern "C" void memset(void *dst, char src, size_t len) {
- HCore::rt_set_memory(dst, src, len);
+ NewOS::rt_set_memory(dst, src, len);
}
extern "C" void memcpy(void *dst, void *src, size_t len) {
- HCore::rt_copy_memory(src, dst, len);
+ NewOS::rt_copy_memory(src, dst, len);
}
diff --git a/Private/Source/Variant.cxx b/Private/Source/Variant.cxx
index 2a9fd5a0..065d562e 100644
--- a/Private/Source/Variant.cxx
+++ b/Private/Source/Variant.cxx
@@ -6,7 +6,7 @@
#include <NewKit/Variant.hpp>
-namespace HCore {
+namespace NewOS {
const Char* Variant::ToString() {
if (m_Ptr == nullptr) {
return ("Memory:{Nullptr}");
@@ -22,4 +22,4 @@ const Char* Variant::ToString() {
}
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/StorageKit/AHCI.hpp b/Private/StorageKit/AHCI.hpp
index 1eac212e..20cddf3f 100644
--- a/Private/StorageKit/AHCI.hpp
+++ b/Private/StorageKit/AHCI.hpp
@@ -9,7 +9,7 @@
#include <KernelKit/DeviceManager.hpp>
#include <NewKit/OwnPtr.hpp>
-namespace HCore {
+namespace NewOS {
class AHCIPacket;
class AHCIDeviceInterface : public DeviceInterface<AHCIPacket> {
@@ -37,4 +37,4 @@ class AHCIPacket final {
Lba Begin;
Lba End;
};
-} // namespace HCore \ No newline at end of file
+} // namespace NewOS \ No newline at end of file
diff --git a/Private/StorageKit/NVME.hpp b/Private/StorageKit/NVME.hpp
index fc89b3af..d2ed585f 100644
--- a/Private/StorageKit/NVME.hpp
+++ b/Private/StorageKit/NVME.hpp
@@ -9,7 +9,7 @@
#include <KernelKit/DeviceManager.hpp>
#include <NewKit/OwnPtr.hpp>
-namespace HCore {
+namespace NewOS {
class NVMEPacket;
class NVMEDeviceInterface : public DeviceInterface<NVMEPacket> {
@@ -42,4 +42,4 @@ class NVMEPacket final {
Lba Begin;
Lba End;
};
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/StorageKit/PRDT.hpp b/Private/StorageKit/PRDT.hpp
index a07fa6bf..f3f4aa67 100644
--- a/Private/StorageKit/PRDT.hpp
+++ b/Private/StorageKit/PRDT.hpp
@@ -9,9 +9,9 @@
#include <KernelKit/PCI/Dma.hpp>
#include <KernelKit/PCI/Iterator.hpp>
-#define kPrdtTransferSize (sizeof(HCore::UShort))
+#define kPrdtTransferSize (sizeof(NewOS::UShort))
-namespace HCore {
+namespace NewOS {
class PRDT final {
public:
explicit PRDT() = delete;
@@ -42,4 +42,4 @@ class PRDT final {
};
using PhysicalAddress = PRDT; // here
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/StorageKit/Storage.hpp b/Private/StorageKit/Storage.hpp
index 1fe74094..6654c62b 100644
--- a/Private/StorageKit/Storage.hpp
+++ b/Private/StorageKit/Storage.hpp
@@ -10,7 +10,7 @@
#include <StorageKit/NVME.hpp>
#include <StorageKit/AHCI.hpp>
-typedef HCore::UInt16 SKScsiPacket[12];
+typedef NewOS::UInt16 SKScsiPacket[12];
extern const SKScsiPacket kCDRomPacketTemplate;
diff --git a/Private/StorageKit/StorageCore.inl b/Private/StorageKit/StorageCore.inl
index 3288b4a2..8a7ca0b9 100644
--- a/Private/StorageKit/StorageCore.inl
+++ b/Private/StorageKit/StorageCore.inl
@@ -12,7 +12,7 @@
/// @file StorageCore.inl
/// @brief Storage Management API.
-namespace HCore {
+namespace NewOS {
typedef Char* SKStr;
///! @brief Storage context, reads and write file according to the descriptor
@@ -36,6 +36,6 @@ class StorageInterface {
virtual PacketDescriptor* Read(const SKStr name) = 0;
virtual Int32 Write(PacketDescriptor* packet, const SKStr name) = 0;
};
-} // namespace HCore
+} // namespace NewOS
#endif /* ifndef __STORAGEKIT_STORAGECORE_INL__ */
diff --git a/Private/makefile b/Private/makefile
index bf068f14..b8bd757e 100644
--- a/Private/makefile
+++ b/Private/makefile
@@ -5,7 +5,7 @@
CC = x86_64-w64-mingw32-gcc
LD = x86_64-w64-mingw32-ld
-CCFLAGS = -c -ffreestanding -mgeneral-regs-only -mno-red-zone -fno-rtti -fno-exceptions -std=c++20 -D__FSKIT_NEWFS__ -D__KERNEL__ -D__HAVE_HCORE_APIS__ -D__HCORE__ -I../ -I./
+CCFLAGS = -c -ffreestanding -mgeneral-regs-only -mno-red-zone -fno-rtti -fno-exceptions -std=c++20 -D__FSKIT_NEWFS__ -D__KERNEL__ -D__HAVE_MAHROUSS_APIS__ -D__MAHROUSS__ -I../ -I./
ASM = nasm
# Add assembler, linker, and object files variables.