mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 10:48:11 +00:00
Kernel: Don't register thread as custom data for WaitQueueBlocker
When adding a WaitQueueBlocker to a WaitQueue, it stored the blocked thread in the registration's custom "void* data" slot. This was only used to print the Thread* in some debug logging. Now that Blocker always knows its origin Thread, we can simply add a Blocker::thread() accessor and then get the blocked Thread& from there. No need to register custom data.
This commit is contained in:
parent
a58c4bbcf5
commit
2c74533ba6
4 changed files with 13 additions and 15 deletions
|
@ -116,7 +116,7 @@ bool Thread::JoinBlocker::unblock(void* value, bool from_add_blocker)
|
|||
Thread::WaitQueueBlocker::WaitQueueBlocker(WaitQueue& wait_queue, StringView block_reason)
|
||||
: m_block_reason(block_reason)
|
||||
{
|
||||
if (!add_to_blocker_set(wait_queue, Thread::current()))
|
||||
if (!add_to_blocker_set(wait_queue))
|
||||
m_should_block = false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue