mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 06:27:45 +00:00
Kernel: Mark sys$alarm as not needing the big lock
Access to Process::m_alarm_timer is serialized via SpinlockProtected, so there's no longer need for this syscall to use the big lock.
This commit is contained in:
parent
496d918e92
commit
5759ea19fb
2 changed files with 3 additions and 3 deletions
|
@ -12,10 +12,10 @@ namespace Kernel {
|
|||
|
||||
ErrorOr<FlatPtr> Process::sys$alarm(unsigned seconds)
|
||||
{
|
||||
VERIFY_PROCESS_BIG_LOCK_ACQUIRED(this);
|
||||
VERIFY_NO_PROCESS_BIG_LOCK(this);
|
||||
TRY(require_promise(Pledge::stdio));
|
||||
unsigned previous_alarm_remaining = 0;
|
||||
return m_alarm_timer.with([&](auto& timer) -> ErrorOr<FlatPtr> {
|
||||
unsigned previous_alarm_remaining = 0;
|
||||
if (timer) {
|
||||
bool was_in_use = false;
|
||||
if (TimerQueue::the().cancel_timer(*timer, &was_in_use)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue