diff options
| author | marcel.braun <marcel.braun@ost.ch> | 2026-02-28 15:18:56 +0100 |
|---|---|---|
| committer | Lukas Oesch <lukasoesch20@gmail.com> | 2026-03-17 16:42:16 +0100 |
| commit | 7a9bdbc58361ff22491785d778474571035ad697 (patch) | |
| tree | 6b3d39464a3ae4f570caf6a0af1123e88061ac27 /kernel/devices/include | |
| parent | 296d58550e8e1202d83e66034c24e9454a1b67dc (diff) | |
| download | teachos-7a9bdbc58361ff22491785d778474571035ad697.tar.xz teachos-7a9bdbc58361ff22491785d778474571035ad697.zip | |
Implement basic structure of storage management
Diffstat (limited to 'kernel/devices/include')
| -rw-r--r-- | kernel/devices/include/devices/storage/StorageManagement.hpp | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/kernel/devices/include/devices/storage/StorageManagement.hpp b/kernel/devices/include/devices/storage/StorageManagement.hpp index 2b2eb22..9098312 100644 --- a/kernel/devices/include/devices/storage/StorageManagement.hpp +++ b/kernel/devices/include/devices/storage/StorageManagement.hpp @@ -1,15 +1,29 @@ #ifndef TEACH_OS_KERNEL_DEVICES_STORAGE_STORAGE_MANAGEMENT_HPP #define TEACH_OS_KERNEL_DEVICES_STORAGE_STORAGE_MANAGEMENT_HPP +#include "devices/BlockDevice.hpp" +#include "devices/storage/StorageController.hpp" + +#include <array> + namespace devices::storage { struct storage_management { - //! @qualifier kernel-defined - //! Initialize the storage management subsystem. - auto init() -> void; + // TODO BA-FS26 add documentation + + auto static init() -> void; + auto static get() -> storage_management &; + + auto add_controller(storage_controller * controller) -> void; + + auto add_device(block_device * device) -> void; private: + storage_management() = default; + + std::array<storage_controller *, 1> m_controllers{}; // TODO BA-FS26 use kstd::vector + std::array<block_device *, 1> m_devices{}; // TODO BA-FS26 use kstd::vector }; } // namespace devices::storage |
