blob: 0ac9cf80c42924cbfecfb2082b2f2bda9e8c3e33 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
#include "kernel/filesystem/filesystem.hpp"
#include "kapi/devices/device.hpp"
#include "kernel/filesystem/inode.hpp"
#include <kstd/memory>
namespace kernel::filesystem
{
auto filesystem::mount(kstd::shared_ptr<kapi::devices::device> const & device) -> int
{
if (!device)
{
return -1; // TODO BA-FS26 panic or errorcode?
}
m_device = device;
return 0;
}
auto filesystem::root_inode() const -> kstd::shared_ptr<inode> const &
{
return m_root_inode;
}
} // namespace kernel::filesystem
|