diff options
| author | Amlal El Mahrouss <amlalelmahrouss@icloud.com> | 2024-03-05 16:09:44 +0000 |
|---|---|---|
| committer | Amlal El Mahrouss <amlalelmahrouss@icloud.com> | 2024-03-05 16:09:44 +0000 |
| commit | b05e715e1f02df785e05182604b7be2ddf6d0b32 (patch) | |
| tree | cd4996aa33a5e499a78bf1f22470d570abacb505 | |
| parent | 357e7a82bc85acee0ed05c6dc0fd870990859df9 (diff) | |
| parent | f7644047cab4827d2ea8d8e33db8f08b640e21d8 (diff) | |
Merge branch 'unstable-user-heap' into 'trunk'
Update 3 files
See merge request mahrouss-logic/micro-kernel!9
| -rw-r--r-- | Private/NewKit/UserHeap.hpp | 7 | ||||
| -rw-r--r-- | Private/Source/URL.cxx | 6 | ||||
| -rw-r--r-- | Private/Source/UserHeap.cxx | 11 |
3 files changed, 14 insertions, 10 deletions
diff --git a/Private/NewKit/UserHeap.hpp b/Private/NewKit/UserHeap.hpp index d69dfe42..1bf1997f 100644 --- a/Private/NewKit/UserHeap.hpp +++ b/Private/NewKit/UserHeap.hpp @@ -28,13 +28,6 @@ enum { kPoolRw = 0x8, }; -struct HeapHeader final { - UInt32 Magic; - Int32 Flags; - Boolean Free; - UIntPtr Pad; -}; - VoidPtr ke_new_heap(Int32 flags); Int32 ke_free_heap(voidPtr pointer); } // namespace HCore diff --git a/Private/Source/URL.cxx b/Private/Source/URL.cxx index ae88678a..8c569f87 100644 --- a/Private/Source/URL.cxx +++ b/Private/Source/URL.cxx @@ -20,12 +20,12 @@ constexpr const char *kURLProtocols[] = { "http", // http without the secure "file", // filesystem protocol "ftp", // file transfer protocol - "params", // system settings - "rsh", // remote shell (gui) + "krnlconf", // system settings + "guisys", // remote shell (gui) }; constexpr const int kUrlOutSz = 3; //! :// -constexpr const int kProtosCount = 8; +constexpr const int kProtosCount = 6; constexpr const int kRangeSz = 4096; static ErrorOr<StringView> url_extract_location(const char *url) { diff --git a/Private/Source/UserHeap.cxx b/Private/Source/UserHeap.cxx index 35dfc429..b9015920 100644 --- a/Private/Source/UserHeap.cxx +++ b/Private/Source/UserHeap.cxx @@ -15,6 +15,17 @@ namespace HCore { /** + * @brief Process Heap Header + * @note Allocated per process, do not allocate twice! +*/ +struct HeapHeader final { + UInt32 Magic; + Int32 Flags; + Boolean Free; + UIntPtr Pad; +}; + +/** * @brief User Heap Manager class, takes care of allocating the process pools. * @note This rely on Virtual Memory! Consider adding good vmem support when * @note porting to a new arch. |
