Kernel: Remove the mount test from VFS

This commit is contained in:
Bananymous 2023-03-30 11:43:24 +03:00
parent 3508df67b1
commit 5d5487315f
3 changed files with 0 additions and 23 deletions

View File

@ -18,7 +18,6 @@ namespace Kernel
virtual BAN::RefPtr<Inode> root_inode() override { return m_root_inode; }
BAN::ErrorOr<void> mount_test();
BAN::ErrorOr<void> mount(FileSystem*, BAN::StringView);
struct File

View File

@ -119,26 +119,6 @@ namespace Kernel
return {};
}
BAN::ErrorOr<void> VirtualFileSystem::mount_test()
{
for (auto* controller : m_storage_controllers)
{
for (auto* device : controller->devices())
{
for (auto& partition : device->partitions())
{
if (partition.label() == "mount-test"sv)
{
auto ext2fs = TRY(Ext2FS::create(partition));
TRY(mount(ext2fs, "/mnt"sv));
return {};
}
}
}
}
return BAN::Error::from_c_string("Could not find mount-test partition");
}
BAN::ErrorOr<void> VirtualFileSystem::mount(FileSystem* file_system, BAN::StringView path)
{
auto file = TRY(file_from_absolute_path(path));

View File

@ -208,8 +208,6 @@ void init2(void* tty1_ptr)
DeviceManager::initialize();
MUST(VirtualFileSystem::initialize());
if (auto res = VirtualFileSystem::get().mount_test(); res.is_error())
dwarnln("{}", res.error());
if (auto res = PS2Controller::initialize(); res.is_error())
dprintln("{}", res.error());