summaryrefslogtreecommitdiff
path: root/src/core/hle/kernel/mutex.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/hle/kernel/mutex.h')
-rw-r--r--src/core/hle/kernel/mutex.h20
1 files changed, 12 insertions, 8 deletions
diff --git a/src/core/hle/kernel/mutex.h b/src/core/hle/kernel/mutex.h
index 1746360e4..53c3dc1f1 100644
--- a/src/core/hle/kernel/mutex.h
+++ b/src/core/hle/kernel/mutex.h
@@ -5,9 +5,7 @@
5#pragma once 5#pragma once
6 6
7#include <string> 7#include <string>
8
9#include "common/common_types.h" 8#include "common/common_types.h"
10
11#include "core/hle/kernel/kernel.h" 9#include "core/hle/kernel/kernel.h"
12 10
13namespace Kernel { 11namespace Kernel {
@@ -24,15 +22,21 @@ public:
24 */ 22 */
25 static SharedPtr<Mutex> Create(bool initial_locked, std::string name = "Unknown"); 23 static SharedPtr<Mutex> Create(bool initial_locked, std::string name = "Unknown");
26 24
27 std::string GetTypeName() const override { return "Mutex"; } 25 std::string GetTypeName() const override {
28 std::string GetName() const override { return name; } 26 return "Mutex";
27 }
28 std::string GetName() const override {
29 return name;
30 }
29 31
30 static const HandleType HANDLE_TYPE = HandleType::Mutex; 32 static const HandleType HANDLE_TYPE = HandleType::Mutex;
31 HandleType GetHandleType() const override { return HANDLE_TYPE; } 33 HandleType GetHandleType() const override {
34 return HANDLE_TYPE;
35 }
32 36
33 int lock_count; ///< Number of times the mutex has been acquired 37 int lock_count; ///< Number of times the mutex has been acquired
34 std::string name; ///< Name of mutex (optional) 38 std::string name; ///< Name of mutex (optional)
35 SharedPtr<Thread> holding_thread; ///< Thread that has acquired the mutex 39 SharedPtr<Thread> holding_thread; ///< Thread that has acquired the mutex
36 40
37 bool ShouldWait() override; 41 bool ShouldWait() override;
38 void Acquire() override; 42 void Acquire() override;