mirror of
https://github.com/genodelabs/genode.git
synced 2025-06-16 06:08:16 +00:00
base: remove Cancelable_lock
- base/cancelable_lock.h becomes base/lock.h - all members become private within base/lock.h - solely Mutex and Blockade are friends to use base/lock.h Fixes #3819
This commit is contained in:
committed by
Christian Helmuth
parent
0ed7367c97
commit
41380ff769
@ -15,18 +15,18 @@
|
||||
#include <base/mutex.h>
|
||||
#include <hw/assert.h>
|
||||
|
||||
Genode::Cancelable_lock::Cancelable_lock(Genode::Cancelable_lock::State state)
|
||||
Genode::Lock::Lock(Genode::Lock::State state)
|
||||
: _state(state), _owner(nullptr) { }
|
||||
|
||||
|
||||
void Genode::Cancelable_lock::unlock()
|
||||
void Genode::Lock::unlock()
|
||||
{
|
||||
assert(_state == LOCKED);
|
||||
_state = UNLOCKED;
|
||||
}
|
||||
|
||||
|
||||
void Genode::Cancelable_lock::lock()
|
||||
void Genode::Lock::lock()
|
||||
{
|
||||
assert(_state == UNLOCKED);
|
||||
_state = LOCKED;
|
||||
|
Reference in New Issue
Block a user