diff --git a/repos/base-linux/src/core/include/platform_thread.h b/repos/base-linux/src/core/include/platform_thread.h index 1d9e3e6d88..4bb7d9de94 100644 --- a/repos/base-linux/src/core/include/platform_thread.h +++ b/repos/base-linux/src/core/include/platform_thread.h @@ -43,8 +43,8 @@ namespace Genode { struct Registry { - Lock _lock { }; - List _list { }; + Mutex _mutex { }; + List _list { }; void insert(Platform_thread *thread); void remove(Platform_thread *thread); diff --git a/repos/base-linux/src/core/include/rpc_cap_factory.h b/repos/base-linux/src/core/include/rpc_cap_factory.h index eb5d68a8f0..f28c36414d 100644 --- a/repos/base-linux/src/core/include/rpc_cap_factory.h +++ b/repos/base-linux/src/core/include/rpc_cap_factory.h @@ -15,7 +15,6 @@ #define _CORE__INCLUDE__RPC_CAP_FACTORY_H_ #include -#include #include namespace Genode { class Rpc_cap_factory; } diff --git a/repos/base-linux/src/core/platform.cc b/repos/base-linux/src/core/platform.cc index f9d041494e..0a7ca8ecfb 100644 --- a/repos/base-linux/src/core/platform.cc +++ b/repos/base-linux/src/core/platform.cc @@ -12,7 +12,6 @@ */ /* Genode includes */ -#include #include /* base-internal includes */ diff --git a/repos/base-linux/src/core/platform_thread.cc b/repos/base-linux/src/core/platform_thread.cc index ac701eb809..efdaf02719 100644 --- a/repos/base-linux/src/core/platform_thread.cc +++ b/repos/base-linux/src/core/platform_thread.cc @@ -32,21 +32,21 @@ typedef Token Tid_token; void Platform_thread::Registry::insert(Platform_thread *thread) { - Lock::Guard guard(_lock); + Mutex::Guard guard(_mutex); _list.insert(thread); } void Platform_thread::Registry::remove(Platform_thread *thread) { - Lock::Guard guard(_lock); + Mutex::Guard guard(_mutex); _list.remove(thread); } void Platform_thread::Registry::submit_exception(unsigned long pid) { - Lock::Guard guard(_lock); + Mutex::Guard guard(_mutex); /* traverse list to find 'Platform_thread' with matching PID */ for (Platform_thread *curr = _list.first(); curr; curr = curr->next()) { diff --git a/repos/base-linux/src/lib/base/region_map_mmap.cc b/repos/base-linux/src/lib/base/region_map_mmap.cc index 2401e29c65..00f545d282 100644 --- a/repos/base-linux/src/lib/base/region_map_mmap.cc +++ b/repos/base-linux/src/lib/base/region_map_mmap.cc @@ -61,12 +61,12 @@ static bool is_sub_rm_session(Dataspace_capability ds) /** - * Lock for protecting mmap/unmap sequences and region-map meta data + * Mutex for protecting mmap/unmap sequences and region-map meta data */ -static Lock &lock() +static Mutex &mutex() { - static Lock lock; - return lock; + static Mutex mutex { }; + return mutex; } @@ -175,7 +175,7 @@ Region_map::Local_addr Region_map_mmap::attach(Dataspace_capability ds, Region_map::Local_addr local_addr, bool executable, bool writeable) { - Lock::Guard lock_guard(lock()); + Mutex::Guard mutex_guard(mutex()); /* only support attach_at for sub RM sessions */ if (_sub_rm && !use_local_addr) { @@ -320,7 +320,7 @@ Region_map::Local_addr Region_map_mmap::attach(Dataspace_capability ds, void Region_map_mmap::detach(Region_map::Local_addr local_addr) { - Lock::Guard lock_guard(lock()); + Mutex::Guard mutex_guard(mutex()); /* * Cases