From 65be230fdda302b25447f2f09b06e3238bd09e79 Mon Sep 17 00:00:00 2001 From: Liam Date: Sun, 19 Feb 2023 14:42:12 -0500 Subject: service: move hle_ipc from kernel --- src/core/hle/service/pm/pm.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/core/hle/service/pm') diff --git a/src/core/hle/service/pm/pm.cpp b/src/core/hle/service/pm/pm.cpp index 02a4ca13b..ea249c26f 100644 --- a/src/core/hle/service/pm/pm.cpp +++ b/src/core/hle/service/pm/pm.cpp @@ -2,9 +2,9 @@ // SPDX-License-Identifier: GPL-2.0-or-later #include "core/core.h" -#include "core/hle/ipc_helpers.h" #include "core/hle/kernel/k_process.h" #include "core/hle/kernel/kernel.h" +#include "core/hle/service/ipc_helpers.h" #include "core/hle/service/pm/pm.h" #include "core/hle/service/server_manager.h" #include "core/hle/service/service.h" @@ -34,7 +34,7 @@ std::optional SearchProcessList( return *iter; } -void GetApplicationPidGeneric(Kernel::HLERequestContext& ctx, +void GetApplicationPidGeneric(HLERequestContext& ctx, const std::vector& process_list) { const auto process = SearchProcessList(process_list, [](const auto& proc) { return proc->GetProcessID() == Kernel::KProcess::ProcessIDMin; @@ -58,7 +58,7 @@ public: } private: - void GetBootMode(Kernel::HLERequestContext& ctx) { + void GetBootMode(HLERequestContext& ctx) { LOG_DEBUG(Service_PM, "called"); IPC::ResponseBuilder rb{ctx, 3}; @@ -66,7 +66,7 @@ private: rb.PushEnum(boot_mode); } - void SetMaintenanceBoot(Kernel::HLERequestContext& ctx) { + void SetMaintenanceBoot(HLERequestContext& ctx) { LOG_DEBUG(Service_PM, "called"); boot_mode = SystemBootMode::Maintenance; @@ -100,7 +100,7 @@ public: } private: - void GetProcessId(Kernel::HLERequestContext& ctx) { + void GetProcessId(HLERequestContext& ctx) { IPC::RequestParser rp{ctx}; const auto program_id = rp.PopRaw(); @@ -122,12 +122,12 @@ private: rb.Push((*process)->GetProcessID()); } - void GetApplicationProcessId(Kernel::HLERequestContext& ctx) { + void GetApplicationProcessId(HLERequestContext& ctx) { LOG_DEBUG(Service_PM, "called"); GetApplicationPidGeneric(ctx, kernel.GetProcessList()); } - void AtmosphereGetProcessInfo(Kernel::HLERequestContext& ctx) { + void AtmosphereGetProcessInfo(HLERequestContext& ctx) { // https://github.com/Atmosphere-NX/Atmosphere/blob/master/stratosphere/pm/source/impl/pm_process_manager.cpp#L614 // This implementation is incomplete; only a handle to the process is returned. IPC::RequestParser rp{ctx}; @@ -187,7 +187,7 @@ public: } private: - void GetProgramId(Kernel::HLERequestContext& ctx) { + void GetProgramId(HLERequestContext& ctx) { IPC::RequestParser rp{ctx}; const auto process_id = rp.PopRaw(); @@ -208,7 +208,7 @@ private: rb.Push((*process)->GetProgramID()); } - void AtmosphereGetProcessId(Kernel::HLERequestContext& ctx) { + void AtmosphereGetProcessId(HLERequestContext& ctx) { IPC::RequestParser rp{ctx}; const auto program_id = rp.PopRaw(); @@ -255,7 +255,7 @@ public: } private: - void GetApplicationProcessIdForShell(Kernel::HLERequestContext& ctx) { + void GetApplicationProcessIdForShell(HLERequestContext& ctx) { LOG_DEBUG(Service_PM, "called"); GetApplicationPidGeneric(ctx, kernel.GetProcessList()); } -- cgit v1.2.3