summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/core/hle/kernel/k_client_port.h6
-rw-r--r--src/core/hle/kernel/k_client_session.h4
-rw-r--r--src/core/hle/kernel/k_event.h14
-rw-r--r--src/core/hle/kernel/k_port.h3
-rw-r--r--src/core/hle/kernel/k_process.h8
-rw-r--r--src/core/hle/kernel/k_readable_event.h4
-rw-r--r--src/core/hle/kernel/k_resource_limit.h4
-rw-r--r--src/core/hle/kernel/k_server_port.h12
-rw-r--r--src/core/hle/kernel/k_server_session.h6
-rw-r--r--src/core/hle/kernel/k_session.h10
-rw-r--r--src/core/hle/kernel/k_shared_memory.h4
-rw-r--r--src/core/hle/kernel/k_synchronization_object.h4
-rw-r--r--src/core/hle/kernel/k_thread.h10
-rw-r--r--src/core/hle/kernel/k_transfer_memory.h10
-rw-r--r--src/core/hle/kernel/k_writable_event.h2
15 files changed, 48 insertions, 53 deletions
diff --git a/src/core/hle/kernel/k_client_port.h b/src/core/hle/kernel/k_client_port.h
index 8501156e8..f2fff3b01 100644
--- a/src/core/hle/kernel/k_client_port.h
+++ b/src/core/hle/kernel/k_client_port.h
@@ -22,7 +22,7 @@ class KClientPort final : public KSynchronizationObject {
public:
explicit KClientPort(KernelCore& kernel_);
- virtual ~KClientPort() override;
+ ~KClientPort() override;
void Initialize(KPort* parent_, s32 max_sessions_, std::string&& name_);
void OnSessionFinalized();
@@ -49,8 +49,8 @@ public:
bool IsServerClosed() const;
// Overridden virtual functions.
- virtual void Destroy() override;
- virtual bool IsSignaled() const override;
+ void Destroy() override;
+ bool IsSignaled() const override;
ResultCode CreateSession(KClientSession** out);
diff --git a/src/core/hle/kernel/k_client_session.h b/src/core/hle/kernel/k_client_session.h
index 720a8c243..b11d5b4e3 100644
--- a/src/core/hle/kernel/k_client_session.h
+++ b/src/core/hle/kernel/k_client_session.h
@@ -34,7 +34,7 @@ class KClientSession final
public:
explicit KClientSession(KernelCore& kernel_);
- virtual ~KClientSession();
+ ~KClientSession() override;
void Initialize(KSession* parent_, std::string&& name_) {
// Set member variables.
@@ -42,7 +42,7 @@ public:
name = std::move(name_);
}
- virtual void Destroy() override;
+ void Destroy() override;
static void PostDestroy([[maybe_unused]] uintptr_t arg) {}
KSession* GetParent() const {
diff --git a/src/core/hle/kernel/k_event.h b/src/core/hle/kernel/k_event.h
index 9a59ffb70..3d3ec99e2 100644
--- a/src/core/hle/kernel/k_event.h
+++ b/src/core/hle/kernel/k_event.h
@@ -20,23 +20,21 @@ class KEvent final : public KAutoObjectWithSlabHeapAndContainer<KEvent, KAutoObj
public:
explicit KEvent(KernelCore& kernel_);
- virtual ~KEvent();
+ ~KEvent() override;
void Initialize(std::string&& name);
- virtual void Finalize() override;
+ void Finalize() override;
- virtual bool IsInitialized() const override {
+ bool IsInitialized() const override {
return initialized;
}
- virtual uintptr_t GetPostDestroyArgument() const override {
+ uintptr_t GetPostDestroyArgument() const override {
return reinterpret_cast<uintptr_t>(owner);
}
- static void PostDestroy(uintptr_t arg);
-
- virtual KProcess* GetOwner() const override {
+ KProcess* GetOwner() const override {
return owner;
}
@@ -48,6 +46,8 @@ public:
return writable_event;
}
+ static void PostDestroy(uintptr_t arg);
+
private:
KReadableEvent readable_event;
KWritableEvent writable_event;
diff --git a/src/core/hle/kernel/k_port.h b/src/core/hle/kernel/k_port.h
index 960f1f3a3..4018ea2df 100644
--- a/src/core/hle/kernel/k_port.h
+++ b/src/core/hle/kernel/k_port.h
@@ -22,7 +22,7 @@ class KPort final : public KAutoObjectWithSlabHeapAndContainer<KPort, KAutoObjec
public:
explicit KPort(KernelCore& kernel_);
- virtual ~KPort();
+ ~KPort() override;
static void PostDestroy([[maybe_unused]] uintptr_t arg) {}
@@ -59,7 +59,6 @@ private:
ServerClosed = 3,
};
-private:
KServerPort server;
KClientPort client;
State state{State::Invalid};
diff --git a/src/core/hle/kernel/k_process.h b/src/core/hle/kernel/k_process.h
index 123d71cd3..c0656b9af 100644
--- a/src/core/hle/kernel/k_process.h
+++ b/src/core/hle/kernel/k_process.h
@@ -331,19 +331,19 @@ public:
void LoadModule(CodeSet code_set, VAddr base_addr);
- virtual bool IsInitialized() const override {
+ bool IsInitialized() const override {
return is_initialized;
}
static void PostDestroy([[maybe_unused]] uintptr_t arg) {}
- virtual void Finalize();
+ void Finalize() override;
- virtual u64 GetId() const override final {
+ u64 GetId() const override {
return GetProcessID();
}
- virtual bool IsSignaled() const override;
+ bool IsSignaled() const override;
void PinCurrentThread();
void UnpinCurrentThread();
diff --git a/src/core/hle/kernel/k_readable_event.h b/src/core/hle/kernel/k_readable_event.h
index 33cd1dd3e..b2850ac7b 100644
--- a/src/core/hle/kernel/k_readable_event.h
+++ b/src/core/hle/kernel/k_readable_event.h
@@ -31,8 +31,8 @@ public:
return parent;
}
- virtual bool IsSignaled() const override;
- virtual void Destroy() override;
+ bool IsSignaled() const override;
+ void Destroy() override;
ResultCode Signal();
ResultCode Clear();
diff --git a/src/core/hle/kernel/k_resource_limit.h b/src/core/hle/kernel/k_resource_limit.h
index 0debbbb51..fab6005ff 100644
--- a/src/core/hle/kernel/k_resource_limit.h
+++ b/src/core/hle/kernel/k_resource_limit.h
@@ -37,10 +37,10 @@ class KResourceLimit final
public:
explicit KResourceLimit(KernelCore& kernel_);
- virtual ~KResourceLimit();
+ ~KResourceLimit() override;
void Initialize(const Core::Timing::CoreTiming* core_timing_);
- virtual void Finalize() override;
+ void Finalize() override;
s64 GetLimitValue(LimitableResource which) const;
s64 GetCurrentValue(LimitableResource which) const;
diff --git a/src/core/hle/kernel/k_server_port.h b/src/core/hle/kernel/k_server_port.h
index d1a757ec3..55481d63f 100644
--- a/src/core/hle/kernel/k_server_port.h
+++ b/src/core/hle/kernel/k_server_port.h
@@ -25,12 +25,9 @@ class SessionRequestHandler;
class KServerPort final : public KSynchronizationObject {
KERNEL_AUTOOBJECT_TRAITS(KServerPort, KSynchronizationObject);
-private:
- using SessionList = boost::intrusive::list<KServerSession>;
-
public:
explicit KServerPort(KernelCore& kernel_);
- virtual ~KServerPort() override;
+ ~KServerPort() override;
void Initialize(KPort* parent_, std::string&& name_);
@@ -63,13 +60,14 @@ public:
bool IsLight() const;
// Overridden virtual functions.
- virtual void Destroy() override;
- virtual bool IsSignaled() const override;
+ void Destroy() override;
+ bool IsSignaled() const override;
private:
+ using SessionList = boost::intrusive::list<KServerSession>;
+
void CleanupSessions();
-private:
SessionList session_list;
SessionRequestHandlerPtr session_handler;
KPort* parent{};
diff --git a/src/core/hle/kernel/k_server_session.h b/src/core/hle/kernel/k_server_session.h
index dd4de2904..27b757ad2 100644
--- a/src/core/hle/kernel/k_server_session.h
+++ b/src/core/hle/kernel/k_server_session.h
@@ -42,9 +42,9 @@ class KServerSession final : public KSynchronizationObject,
public:
explicit KServerSession(KernelCore& kernel_);
- virtual ~KServerSession() override;
+ ~KServerSession() override;
- virtual void Destroy() override;
+ void Destroy() override;
void Initialize(KSession* parent_, std::string&& name_);
@@ -56,7 +56,7 @@ public:
return parent;
}
- virtual bool IsSignaled() const override;
+ bool IsSignaled() const override;
void OnClientClosed();
diff --git a/src/core/hle/kernel/k_session.h b/src/core/hle/kernel/k_session.h
index a981fd1f6..4ddd080d2 100644
--- a/src/core/hle/kernel/k_session.h
+++ b/src/core/hle/kernel/k_session.h
@@ -18,17 +18,17 @@ class KSession final : public KAutoObjectWithSlabHeapAndContainer<KSession, KAut
public:
explicit KSession(KernelCore& kernel_);
- virtual ~KSession() override;
+ ~KSession() override;
void Initialize(KClientPort* port_, const std::string& name_);
- virtual void Finalize() override;
+ void Finalize() override;
- virtual bool IsInitialized() const override {
+ bool IsInitialized() const override {
return initialized;
}
- virtual uintptr_t GetPostDestroyArgument() const override {
+ uintptr_t GetPostDestroyArgument() const override {
return reinterpret_cast<uintptr_t>(process);
}
@@ -78,7 +78,6 @@ private:
ServerClosed = 3,
};
-private:
void SetState(State state) {
atomic_state = static_cast<u8>(state);
}
@@ -87,7 +86,6 @@ private:
return static_cast<State>(atomic_state.load(std::memory_order_relaxed));
}
-private:
KServerSession server;
KClientSession client;
std::atomic<std::underlying_type_t<State>> atomic_state{
diff --git a/src/core/hle/kernel/k_shared_memory.h b/src/core/hle/kernel/k_shared_memory.h
index 553a56327..e9815f90b 100644
--- a/src/core/hle/kernel/k_shared_memory.h
+++ b/src/core/hle/kernel/k_shared_memory.h
@@ -68,9 +68,9 @@ public:
return device_memory->GetPointer(physical_address + offset);
}
- virtual void Finalize() override;
+ void Finalize() override;
- virtual bool IsInitialized() const override {
+ bool IsInitialized() const override {
return is_initialized;
}
static void PostDestroy([[maybe_unused]] uintptr_t arg) {}
diff --git a/src/core/hle/kernel/k_synchronization_object.h b/src/core/hle/kernel/k_synchronization_object.h
index a41dd1220..3d4ce1fbc 100644
--- a/src/core/hle/kernel/k_synchronization_object.h
+++ b/src/core/hle/kernel/k_synchronization_object.h
@@ -29,7 +29,7 @@ public:
KSynchronizationObject** objects, const s32 num_objects,
s64 timeout);
- virtual void Finalize() override;
+ void Finalize() override;
[[nodiscard]] virtual bool IsSignaled() const = 0;
@@ -37,7 +37,7 @@ public:
protected:
explicit KSynchronizationObject(KernelCore& kernel);
- virtual ~KSynchronizationObject();
+ ~KSynchronizationObject() override;
virtual void OnFinalizeSynchronizationObject() {}
diff --git a/src/core/hle/kernel/k_thread.h b/src/core/hle/kernel/k_thread.h
index 4abfc2b49..01eebb165 100644
--- a/src/core/hle/kernel/k_thread.h
+++ b/src/core/hle/kernel/k_thread.h
@@ -358,21 +358,21 @@ public:
return termination_requested || GetRawState() == ThreadState::Terminated;
}
- [[nodiscard]] virtual u64 GetId() const override final {
+ [[nodiscard]] u64 GetId() const override {
return this->GetThreadID();
}
- [[nodiscard]] virtual bool IsInitialized() const override {
+ [[nodiscard]] bool IsInitialized() const override {
return initialized;
}
- [[nodiscard]] virtual uintptr_t GetPostDestroyArgument() const override {
+ [[nodiscard]] uintptr_t GetPostDestroyArgument() const override {
return reinterpret_cast<uintptr_t>(parent) | (resource_limit_release_hint ? 1 : 0);
}
- virtual void Finalize() override;
+ void Finalize() override;
- [[nodiscard]] virtual bool IsSignaled() const override;
+ [[nodiscard]] bool IsSignaled() const override;
static void PostDestroy(uintptr_t arg);
diff --git a/src/core/hle/kernel/k_transfer_memory.h b/src/core/hle/kernel/k_transfer_memory.h
index c2d0f1eaf..31029a5c2 100644
--- a/src/core/hle/kernel/k_transfer_memory.h
+++ b/src/core/hle/kernel/k_transfer_memory.h
@@ -27,23 +27,23 @@ class KTransferMemory final
public:
explicit KTransferMemory(KernelCore& kernel_);
- virtual ~KTransferMemory() override;
+ ~KTransferMemory() override;
ResultCode Initialize(VAddr address_, std::size_t size_, Svc::MemoryPermission owner_perm_);
- virtual void Finalize() override;
+ void Finalize() override;
- virtual bool IsInitialized() const override {
+ bool IsInitialized() const override {
return is_initialized;
}
- virtual uintptr_t GetPostDestroyArgument() const override {
+ uintptr_t GetPostDestroyArgument() const override {
return reinterpret_cast<uintptr_t>(owner);
}
static void PostDestroy(uintptr_t arg);
- KProcess* GetOwner() const {
+ KProcess* GetOwner() const override {
return owner;
}
diff --git a/src/core/hle/kernel/k_writable_event.h b/src/core/hle/kernel/k_writable_event.h
index 607b0eadb..858d982c4 100644
--- a/src/core/hle/kernel/k_writable_event.h
+++ b/src/core/hle/kernel/k_writable_event.h
@@ -21,7 +21,7 @@ public:
explicit KWritableEvent(KernelCore& kernel_);
~KWritableEvent() override;
- virtual void Destroy() override;
+ void Destroy() override;
static void PostDestroy([[maybe_unused]] uintptr_t arg) {}