diff options
author | Liav A <liavalb@gmail.com> | 2023-05-26 13:20:10 +0300 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2023-05-27 10:58:58 +0200 |
commit | 902dac7f5fa7e116ba495a4a9dbd13f0bf3ec07f (patch) | |
tree | 828927ade474f57fd68321f01313d88c2ba0443b /Kernel | |
parent | bce17d06f50ee993439a3caa049190bc2fcea21a (diff) | |
download | serenity-902dac7f5fa7e116ba495a4a9dbd13f0bf3ec07f.zip |
Kernel: Don't lock ProcFS mutex when calling traverse_as_directory
This is not needed, because when we are doing this traversing, functions
that are called from this function are using proper and more "atomic"
locking.
Diffstat (limited to 'Kernel')
-rw-r--r-- | Kernel/FileSystem/ProcFS/Inode.cpp | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/Kernel/FileSystem/ProcFS/Inode.cpp b/Kernel/FileSystem/ProcFS/Inode.cpp index 7140ea7e4d..f7845a26eb 100644 --- a/Kernel/FileSystem/ProcFS/Inode.cpp +++ b/Kernel/FileSystem/ProcFS/Inode.cpp @@ -124,7 +124,6 @@ ErrorOr<void> ProcFSInode::traverse_as_root_directory(Function<ErrorOr<void>(Fil ErrorOr<void> ProcFSInode::traverse_as_directory(Function<ErrorOr<void>(FileSystem::DirectoryEntryView const&)> callback) const { - MutexLocker locker(procfs().m_lock); if (m_type == Type::ProcessSubdirectory) { VERIFY(m_associated_pid.has_value()); auto process = Process::from_pid_in_same_jail(m_associated_pid.value()); @@ -174,7 +173,6 @@ ErrorOr<NonnullRefPtr<Inode>> ProcFSInode::lookup_as_root_directory(StringView n ErrorOr<NonnullRefPtr<Inode>> ProcFSInode::lookup(StringView name) { - MutexLocker locker(procfs().m_lock); if (m_type == Type::ProcessSubdirectory) { VERIFY(m_associated_pid.has_value()); auto process = Process::from_pid_in_same_jail(m_associated_pid.value()); |