From b742349ba039d1a864462332bb7ae5a071afdec1 Mon Sep 17 00:00:00 2001 From: "marcel.braun" Date: Tue, 24 Mar 2026 16:53:21 +0100 Subject: Refactor mount_table entry (mount) to use dentry as key instead of path --- kernel/include/kernel/filesystem/mount.hpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'kernel/include') diff --git a/kernel/include/kernel/filesystem/mount.hpp b/kernel/include/kernel/filesystem/mount.hpp index 232a9be..dd47ce7 100644 --- a/kernel/include/kernel/filesystem/mount.hpp +++ b/kernel/include/kernel/filesystem/mount.hpp @@ -1,23 +1,22 @@ #ifndef TEACH_OS_KERNEL_FILESYSTEM_MOUNT_HPP #define TEACH_OS_KERNEL_FILESYSTEM_MOUNT_HPP +#include "kernel/filesystem/dentry.hpp" #include "kernel/filesystem/filesystem.hpp" #include -#include - namespace filesystem { struct mount { - mount(std::string_view const & path, kstd::shared_ptr const & fs); + mount(kstd::shared_ptr const & mount_dentry, kstd::shared_ptr const & fs); - [[nodiscard]] auto path() const -> std::string_view; + [[nodiscard]] auto get_dentry() const -> kstd::shared_ptr; [[nodiscard]] auto get_filesystem() const -> kstd::shared_ptr const &; private: - std::string_view m_path; + kstd::shared_ptr m_dentry; kstd::shared_ptr m_filesystem{}; }; } // namespace filesystem -- cgit v1.2.3