1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 18:17:44 +00:00

Kernel: Rename ProtectedValue<T> => MutexProtected<T>

Let's make it obvious what we're protecting it with.
This commit is contained in:
Andreas Kling 2021-08-21 23:31:15 +02:00
parent 81d990b551
commit c2fc33becd
18 changed files with 57 additions and 56 deletions

View file

@ -7,7 +7,7 @@
#pragma once
#include <Kernel/FileSystem/FileBackedFileSystem.h>
#include <Kernel/Locking/ProtectedValue.h>
#include <Kernel/Locking/MutexProtected.h>
namespace Kernel {
@ -44,7 +44,7 @@ private:
DiskCache& cache() const;
void flush_specific_block_if_needed(BlockIndex index);
mutable ProtectedValue<OwnPtr<DiskCache>> m_cache;
mutable MutexProtected<OwnPtr<DiskCache>> m_cache;
};
}

View file

@ -10,13 +10,13 @@
#include <AK/Vector.h>
#include <Kernel/FileSystem/Custody.h>
#include <Kernel/FileSystem/Inode.h>
#include <Kernel/Locking/ProtectedValue.h>
#include <Kernel/Locking/MutexProtected.h>
namespace Kernel {
static Singleton<ProtectedValue<Custody::AllCustodiesList>> s_all_custodies;
static Singleton<MutexProtected<Custody::AllCustodiesList>> s_all_custodies;
static ProtectedValue<Custody::AllCustodiesList>& all_custodies()
static MutexProtected<Custody::AllCustodiesList>& all_custodies()
{
return s_all_custodies;
}

View file

@ -20,7 +20,7 @@
#include <Kernel/FileSystem/UnveilNode.h>
#include <Kernel/Forward.h>
#include <Kernel/KResult.h>
#include <Kernel/Locking/ProtectedValue.h>
#include <Kernel/Locking/MutexProtected.h>
namespace Kernel {
@ -93,7 +93,7 @@ private:
RefPtr<Inode> m_root_inode;
RefPtr<Custody> m_root_custody;
ProtectedValue<Vector<Mount, 16>> m_mounts;
MutexProtected<Vector<Mount, 16>> m_mounts;
};
}