Index: src/libcfa/concurrency/kernel
===================================================================
--- src/libcfa/concurrency/kernel	(revision b227f6896f9a2f0cc65768eef401bb62ec7dc754)
+++ src/libcfa/concurrency/kernel	(revision 9a1e509e6ded571c2f6355253b2c7bfa0b4a2340)
@@ -33,15 +33,15 @@
 void unlock    ( spinlock * );
 
-struct signal_once {
-	volatile bool cond;
-	struct spinlock lock;
-	struct __thread_queue_t blocked;
+struct semaphore {
+	spinlock lock;
+	int count;
+	__thread_queue_t waiting;
 };
 
-void ?{}(signal_once * this);
-void ^?{}(signal_once * this);
+void  ?{}(semaphore * this, int count = 1);
+void ^?{}(semaphore * this);
+void P(semaphore * this);
+void V(semaphore * this);
 
-void wait( signal_once * );
-void signal( signal_once * );
 
 //-----------------------------------------------------------------------------
@@ -81,5 +81,5 @@
 	pthread_t kernel_thread;
 
-	signal_once terminated;
+	semaphore terminated;
 	volatile bool is_terminated;
 
