summaryrefslogtreecommitdiff
path: root/Kernel
diff options
context:
space:
mode:
authorSamuel Bowman <sam@sambowman.tech>2022-08-16 22:52:58 -0400
committerAndreas Kling <kling@serenityos.org>2022-08-18 00:04:31 +0200
commitb5a2f59320713c8868ae2946d667cc280bf74174 (patch)
tree2ff6015e706fb3b66c23fb2d619eec3cf303669f /Kernel
parent146903a3b5d4b156facc61ed5f8fe453c2874ff1 (diff)
downloadserenity-b5a2f59320713c8868ae2946d667cc280bf74174.zip
Kernel: Make sys$unveil() not take the big process lock
The unveil syscall uses the UnveilData struct which is already SpinlockProtected, so there is no need to take the big lock.
Diffstat (limited to 'Kernel')
-rw-r--r--Kernel/API/Syscall.h2
-rw-r--r--Kernel/Syscalls/unveil.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/Kernel/API/Syscall.h b/Kernel/API/Syscall.h
index af75a4e8c1..389f91d3e4 100644
--- a/Kernel/API/Syscall.h
+++ b/Kernel/API/Syscall.h
@@ -186,7 +186,7 @@ enum class NeedsBigProcessLock {
S(umount, NeedsBigProcessLock::Yes) \
S(uname, NeedsBigProcessLock::No) \
S(unlink, NeedsBigProcessLock::No) \
- S(unveil, NeedsBigProcessLock::Yes) \
+ S(unveil, NeedsBigProcessLock::No) \
S(utime, NeedsBigProcessLock::Yes) \
S(utimensat, NeedsBigProcessLock::Yes) \
S(waitid, NeedsBigProcessLock::Yes) \
diff --git a/Kernel/Syscalls/unveil.cpp b/Kernel/Syscalls/unveil.cpp
index f1e8116451..699cbc8aa6 100644
--- a/Kernel/Syscalls/unveil.cpp
+++ b/Kernel/Syscalls/unveil.cpp
@@ -26,7 +26,7 @@ static void update_intermediate_node_permissions(UnveilNode& root_node, UnveilAc
ErrorOr<FlatPtr> Process::sys$unveil(Userspace<Syscall::SC_unveil_params const*> user_params)
{
- VERIFY_PROCESS_BIG_LOCK_ACQUIRED(this);
+ VERIFY_NO_PROCESS_BIG_LOCK(this);
auto params = TRY(copy_typed_from_user(user_params));
if (!params.path.characters && !params.permissions.characters) {