diff options
| author | Amlal El Mahrouss <amlal@nekernel.org> | 2025-04-23 09:11:33 +0200 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal@nekernel.org> | 2025-04-23 09:21:50 +0200 |
| commit | 8c500f29bd0ef17f5b59e5be49f4cae88d827d85 (patch) | |
| tree | adce743ad0a20fde024cf7024b1813357b69f5e5 /dev/kernel/SwapKit | |
| parent | bb1d9fa4b7b2c680ed3c0ca16c060dd991bda16f (diff) | |
dev, kernel: scheduler and disk swap refactors.
Details:
- Reworked SCSI groundwork to prepare for a Generic SCSI driver.
- Refatored scheduler's code with the new coding style for
structs.
- Add Leak and LeakBlob inside PROCESS_IMAGE struct.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'dev/kernel/SwapKit')
| -rw-r--r-- | dev/kernel/SwapKit/DiskSwap.h | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/dev/kernel/SwapKit/DiskSwap.h b/dev/kernel/SwapKit/DiskSwap.h index 0e32eff5..78b1a896 100644 --- a/dev/kernel/SwapKit/DiskSwap.h +++ b/dev/kernel/SwapKit/DiskSwap.h @@ -9,9 +9,10 @@ #include <NewKit/Defines.h> #include <CompilerKit/CompilerKit.h> +#include <hint/CompilerHint.h> #define kSwapBlockMaxSize (mib_cast(16)) -#define kSwapPageFile "/boot/pagefile.sys" +#define kSwapPageFilePath "/boot/pagefile.sys" /// @file SwapDisk.h /// @brief Virtual memory swap disk. @@ -19,15 +20,18 @@ namespace Kernel { struct SWAP_DISK_HEADER; + class DiskSwapInterface; /// @brief Virtual memory interface to swap memory chunks onto disk. - class SwapDiskInterface final + /// @note The class only supports the NeFS as of right now, as it is using forks to write data into disk. + class DiskSwapInterface final { public: - explicit SwapDiskInterface() = default; - ~SwapDiskInterface() = default; + explicit DiskSwapInterface() = default; + ~DiskSwapInterface() = default; - NE_COPY_DEFAULT(SwapDiskInterface) + NE_COPY_DELETE(DiskSwapInterface) + NE_MOVE_DELETE(DiskSwapInterface) public: /***********************************************************************************/ @@ -46,7 +50,7 @@ namespace Kernel /// @param data the data packet length. /// @return Whether the swap was fetched to disk, or not. /***********************************************************************************/ - SWAP_DISK_HEADER* Read(const Char* fork_name, SizeT fork_name_len, SizeT data_len); + _Output SWAP_DISK_HEADER* Read(const Char* fork_name, SizeT fork_name_len, SizeT data_len); }; /// @brief Swap disk header, containing information about the held virtual memory. |
