From c7b637d7b68d9b7e271e70a5a5cc0c4fcf9172de Mon Sep 17 00:00:00 2001 From: Amlal El Mahrouss Date: Sat, 12 Oct 2024 19:20:29 +0200 Subject: IMP: Porting stack to AARCH64. - Bootloader and kernel were made to be ported to mulitple platforms. - Some part of the stack have to be written specifically for the platform though. Signed-off-by: Amlal El Mahrouss --- dev/zba/BootKit/BootKit.hxx | 1 - dev/zba/BootKit/HW/ATA.hxx | 2 +- dev/zba/BootKit/Support.hxx | 18 ++++++++++++++++++ 3 files changed, 19 insertions(+), 2 deletions(-) (limited to 'dev/zba/BootKit') diff --git a/dev/zba/BootKit/BootKit.hxx b/dev/zba/BootKit/BootKit.hxx index 12e595e2..4dde8f1e 100644 --- a/dev/zba/BootKit/BootKit.hxx +++ b/dev/zba/BootKit/BootKit.hxx @@ -17,7 +17,6 @@ /// include NeFS header and Support header as well. -#include #include #include diff --git a/dev/zba/BootKit/HW/ATA.hxx b/dev/zba/BootKit/HW/ATA.hxx index 67a8aa97..2d4e6e8b 100644 --- a/dev/zba/BootKit/HW/ATA.hxx +++ b/dev/zba/BootKit/HW/ATA.hxx @@ -23,7 +23,7 @@ public: explicit BootDeviceATA() noexcept; ~BootDeviceATA() = default; - ZKA_COPY_DEFAULT(BootDeviceATA); + ZKA_COPY_DELETE(BootDeviceATA); enum { diff --git a/dev/zba/BootKit/Support.hxx b/dev/zba/BootKit/Support.hxx index 8b9ab105..47270c39 100644 --- a/dev/zba/BootKit/Support.hxx +++ b/dev/zba/BootKit/Support.hxx @@ -14,6 +14,24 @@ #ifdef __NEWOSLDR__ +/// @brief memset definition in C++. +/// @param dst destination pointer. +/// @param byte value to fill in. +/// @param len length of of src. +EXTERN_C void* memset(void* dst, int byte, long long unsigned int len); + +/// @brief memcpy definition in C++. +/// @param dst destination pointer. +/// @param src source pointer. +/// @param len length of of src. +EXTERN_C void* memcpy(void* dst, const void* src, long long unsigned int len); + +/// @brief strlen definition in C++. +EXTERN_C size_t strlen(const char* whatToCheck); + +/// @brief strcmp definition in C++. +EXTERN_C int strcmp(const char* whatToCheck, const char* whatToCheckRight); + #define SetMem(dst, c, sz) memset(dst, c, sz) #define MoveMem(dst, src, sz) memcpy(dst, src, sz) #define CopyMem(dst, src, sz) memcpy(dst, src, sz) -- cgit v1.2.3