mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 10:02:43 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			18 lines
		
	
	
	
		
			319 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			18 lines
		
	
	
	
		
			319 B
		
	
	
	
		
			C++
		
	
	
	
	
	
| #pragma once
 | |
| 
 | |
| #include <AK/SinglyLinkedList.h>
 | |
| #include <Kernel/Thread.h>
 | |
| 
 | |
| class WaitQueue {
 | |
| public:
 | |
|     WaitQueue();
 | |
|     ~WaitQueue();
 | |
| 
 | |
|     void enqueue(Thread&);
 | |
|     void wake_one();
 | |
|     void wake_all();
 | |
| 
 | |
| private:
 | |
|     typedef IntrusiveList<Thread, &Thread::m_wait_queue_node> ThreadList;
 | |
|     ThreadList m_threads;
 | |
| };
 | 
