Kernel: Add spin lock assert back. I had accidentally deleted it
This commit is contained in:
parent
ed0b1a86aa
commit
5d78cd3016
|
@ -7,6 +7,7 @@ namespace Kernel
|
|||
void SpinLock::lock()
|
||||
{
|
||||
pid_t tid = Scheduler::current_tid();
|
||||
ASSERT(tid != m_locker);
|
||||
while (!m_locker.compare_exchange(-1, tid))
|
||||
Scheduler::get().reschedule();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue