semaphore without busy waiting