summaryrefslogtreecommitdiffhomepage
path: root/dev
diff options
context:
space:
mode:
authorAmlal EL Mahrouss <amlalelmahrouss@icloud.com>2024-11-28 18:29:13 +0100
committerAmlal EL Mahrouss <amlalelmahrouss@icloud.com>2024-11-28 18:29:13 +0100
commit49d8bce2413cc9497214cca88584917d9e9088c1 (patch)
tree0fc7d80bdfc94d7518cf6452e6c21db114e42eba /dev
parent3e9f5148faefb6ce73d6d0740504a4e26908cdfd (diff)
IMP: Improve Kernel architecture.
Signed-off-by: Amlal EL Mahrouss <amlalelmahrouss@icloud.com>
Diffstat (limited to 'dev')
-rw-r--r--dev/Modules/FB/WS.h65
-rw-r--r--dev/Modules/WSGL/WSGL.h35
-rw-r--r--dev/ZKAKit/KernelKit/UserProcessScheduler.h11
-rw-r--r--dev/ZKAKit/src/WS/WS.cc7
-rw-r--r--dev/ZKAKit/src/WS/WSGL.cc7
5 files changed, 4 insertions, 121 deletions
diff --git a/dev/Modules/FB/WS.h b/dev/Modules/FB/WS.h
deleted file mode 100644
index f16cabb4..00000000
--- a/dev/Modules/FB/WS.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/* -------------------------------------------
-
- Copyright (C) 2024, ELMH Group, all rights reserved.
-
-------------------------------------------- */
-
-#pragma once
-
-#include <ArchKit/ArchKit.h>
-#include <NewKit/Utils.h>
-
-/// @file WS.h
-/// @brief WindowServer's window ownership implementation.
-/// It is used to draw within a window.
-
-#define rtl_allocate_backbuffer(width, height) new WS::WSBackBufferKind[width * height]
-#define rtl_compute_fb_geometry(width, height) (width * height)
-
-namespace WS
-{
- using namespace Kernel;
-
- class WSWindowTexture;
- class WSWindowContainer;
-
- typedef UInt32* WSBackBufferKind;
-
- class WSWindowContainer final
- {
- public:
- WSWindowContainer() = default;
- ~WSWindowContainer() = default;
-
- ZKA_COPY_DEFAULT(WSWindowContainer);
-
- /// @note the trick is, it could be GPU processed data, that's the cool thing.
- BOOL Fill(WSBackBufferKind contents_buf, SizeT contents_len)
- {
- if (contents_len > BackBufferLength)
- return NO;
-
- if (!contents_buf)
- return NO;
-
- if (!BackBuffer ||
- !BackBufferLength)
- return NO;
-
- rt_copy_memory(contents_buf, BackBuffer, contents_len);
- return YES;
- }
-
- BOOL Fill(WSWindowContainer* container)
- {
- if (!container)
- return NO;
-
- return this->Fill(container->BackBuffer, container->BackBufferLength);
- }
-
- public:
- WSBackBufferKind BackBuffer{nullptr};
- SizeT BackBufferLength{0UL};
- };
-} // namespace WS
diff --git a/dev/Modules/WSGL/WSGL.h b/dev/Modules/WSGL/WSGL.h
deleted file mode 100644
index b1dc8bb5..00000000
--- a/dev/Modules/WSGL/WSGL.h
+++ /dev/null
@@ -1,35 +0,0 @@
-/* -------------------------------------------
-
- Copyright (C) 2024, ELMH Group, all rights reserved.
-
-------------------------------------------- */
-
-#pragma once
-
-#include <NewKit/Defines.h>
-#include <Modules/FB/WS.h>
-
-namespace WS
-{
- /// @brief GPU texture class.
- class WSWindowTexture final
- {
- public:
- explicit WSWindowTexture() = default;
- ~WSWindowTexture() = default;
-
- ZKA_COPY_DEFAULT(WSWindowTexture);
-
- VoidPtr InputData{nullptr};
- VoidPtr ProcessUnit{nullptr};
- BOOL* IsDone{nullptr};
-
- const BOOL TryIsDone()
- {
- if (IsDone && *IsDone)
- return YES;
-
- return NO;
- }
- };
-} // namespace WS
diff --git a/dev/ZKAKit/KernelKit/UserProcessScheduler.h b/dev/ZKAKit/KernelKit/UserProcessScheduler.h
index c32b5b60..e7b023ed 100644
--- a/dev/ZKAKit/KernelKit/UserProcessScheduler.h
+++ b/dev/ZKAKit/KernelKit/UserProcessScheduler.h
@@ -19,11 +19,12 @@
#define kSchedMaxMemoryLimit gib_cast(128)
#define kSchedMaxStackSz mib_cast(8)
-////////////////////////////////////////////////////
-
-// LAST REV: Mon Feb 12 13:52:01 CET 2024
+#define kProcessInvalidID (-1)
+#define kProcessNameLen (128U)
////////////////////////////////////////////////////
+// The current date is: Thu 11/28/2024 //
+////////////////////////////////////////////////////
namespace Kernel
{
@@ -38,10 +39,6 @@ namespace Kernel
//! @brief Local Process identifier.
typedef Int64 ProcessID;
- //! @brief Local Process name length.
- inline constexpr SizeT kProcessNameLen = 128U;
- inline constexpr ProcessID kProcessInvalidID = -1;
-
//! @brief Local Process status enum.
enum class ProcessStatusKind : Int32
{
diff --git a/dev/ZKAKit/src/WS/WS.cc b/dev/ZKAKit/src/WS/WS.cc
deleted file mode 100644
index f58192cd..00000000
--- a/dev/ZKAKit/src/WS/WS.cc
+++ /dev/null
@@ -1,7 +0,0 @@
-/* -------------------------------------------
-
- Copyright (C) 2024, ELMH Group, all rights reserved.
-
-------------------------------------------- */
-
-#include <Modules/FB/WS.h> \ No newline at end of file
diff --git a/dev/ZKAKit/src/WS/WSGL.cc b/dev/ZKAKit/src/WS/WSGL.cc
deleted file mode 100644
index d6875f87..00000000
--- a/dev/ZKAKit/src/WS/WSGL.cc
+++ /dev/null
@@ -1,7 +0,0 @@
-/* -------------------------------------------
-
- Copyright (C) 2024, ELMH Group, all rights reserved.
-
-------------------------------------------- */
-
-#include <Modules/WSGL/WSGL.h> \ No newline at end of file