-
Notifications
You must be signed in to change notification settings - Fork 0
Add ramdisk support and shell commands #232
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Introduce several new data structures and allocator wrappers: - CritBitTree: A binary crit-bit tree for NUL-terminated strings. - LinkedList: Generic single and double linked lists with custom allocators. - LruCache: A fixed-capacity LRU cache. - TaggedPointer: Stores type info in unused pointer bits. - CustomAllocatorWrapper: Enables using custom allocators with containers.
Introduces a comprehensive system for building root filesystems, supporting both initial RAM disks (INITRD) and standalone disk images. This includes: - New `cmake/BashConfigHelpers.cmake` for managing bash configurations. - `register_filesystem` CMake function in `RuntimeHelpers.cmake`. - `rootfs` subdirectory with its own CMake configuration. - `scripts/actions/make_rootfs.bash` and `scripts/rootfs/make_fat.bash` for orchestrating and creating FAT filesystems. - A `ramdisk` feature flag to control INITRD vs. image generation. - New bash helper functions for size conversions. - Fixes a bug in test filtering logic.
Introduces a new `Path` class in `kernel/src/vfs/path.hpp` to provide robust path manipulation capabilities for the Virtual File System. This includes parsing, normalization, component access, concatenation, and comparison of file paths. A comprehensive test suite is also added.
Refactor `OptionalField` in `utils.hpp` from a type alias to a macro to ensure `NO_UNIQUE_ADDRESS` is correctly applied with `std::conditional_t`.
Introduce `DivRoundUp` for safe integer division, `span::get` for structured access to spans, and compile-time array utilities. Add `UNUSED`, `CONCAT`, and `RESERVED` macros. Refactor PMM calculations to use `DivRoundUp` and fix a header guard.
Introduces the core Virtual File System (VFS) framework, including: - Generic VFS interfaces and types for filesystem operations. - Error handling mechanisms (`VfsError`, `Result`). - An in-memory I/O driver for testing and simple storage. - Base FAT filesystem implementation (`Fat` template). - Specific drivers for FAT12, FAT16, and FAT32. - Comprehensive unit tests for FAT12. This lays the foundation for managing various filesystems within the kernel.
Introduces the VFS module, providing a unified interface for filesystem operations like mounting, file, and directory management. Includes core implementation, public API, and comprehensive tests.
Bootloader now locates and passes ramdisk information to the kernel. The VFS module mounts the FAT12 ramdisk at the root filesystem. Introduces 'cd', 'ls', 'cat', and 'pwd' commands to the kernel shell for basic filesystem interaction.
F1r3d3v
added a commit
that referenced
this pull request
Dec 11, 2025
Bootloader now locates and passes ramdisk information to the kernel. The VFS module mounts the FAT12 ramdisk at the root filesystem. Introduces 'cd', 'ls', 'cat', and 'pwd' commands to the kernel shell for basic filesystem interaction.
F1r3d3v
added a commit
that referenced
this pull request
Dec 11, 2025
Bootloader now locates and passes ramdisk information to the kernel. The VFS module mounts the FAT12 ramdisk at the root filesystem. Introduces 'cd', 'ls', 'cat', and 'pwd' commands to the kernel shell for basic filesystem interaction.
Jlisowskyy
pushed a commit
that referenced
this pull request
Jan 7, 2026
Bootloader now locates and passes ramdisk information to the kernel. The VFS module mounts the FAT12 ramdisk at the root filesystem. Introduces 'cd', 'ls', 'cat', and 'pwd' commands to the kernel shell for basic filesystem interaction.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Bootloader now locates and passes ramdisk information to the kernel.
The VFS module mounts the FAT12 ramdisk at the root filesystem.
Introduces 'cd', 'ls', 'cat', and 'pwd' commands to the kernel shell for basic filesystem interaction.