os: refactor/rewrite entire namespace.

This commit is contained in:
Michael Scire 2020-04-08 02:21:35 -07:00
parent 6193283f03
commit 065485b971
181 changed files with 5353 additions and 1929 deletions

View file

@ -30,7 +30,7 @@ namespace ams::fs {
std::free(ptr);
}
os::Mutex g_lock;
os::Mutex g_lock(false);
AllocateFunction g_allocate_func = DefaultAllocate;
DeallocateFunction g_deallocate_func = DefaultDeallocate;

View file

@ -60,7 +60,7 @@ namespace ams::fs::impl {
}
FileSystemAccessor::FileSystemAccessor(const char *n, std::unique_ptr<fsa::IFileSystem> &&fs, std::unique_ptr<fsa::ICommonMountNameGenerator> &&generator)
: impl(std::move(fs)), mount_name_generator(std::move(generator)),
: impl(std::move(fs)), open_list_lock(false), mount_name_generator(std::move(generator)),
access_log_enabled(false), data_cache_attachable(false), path_cache_attachable(false), path_cache_attached(false), multi_commit_supported(false)
{
R_ABORT_UNLESS(ValidateMountName(n));

View file

@ -28,7 +28,7 @@ namespace ams::fs::impl {
FileSystemList fs_list;
os::Mutex mutex;
public:
constexpr MountTable() : fs_list(), mutex() { /* ... */ }
constexpr MountTable() : fs_list(), mutex(false) { /* ... */ }
private:
bool CanAcceptMountName(const char *name);
public: