From c3242abe95ec7b4b2279401ed08affb5b3e3e1da Mon Sep 17 00:00:00 2001 From: Sergi Granell Date: Tue, 8 Feb 2022 19:46:45 +0100 Subject: kernel: svc: Add OutputDebugString32, CreateCodeMemory32, ControlCodeMemory32 Very straightforward, they are just wrappers to the 64-bit version of the SVC. --- src/core/hle/kernel/svc_wrap.h | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'src/core/hle/kernel/svc_wrap.h') diff --git a/src/core/hle/kernel/svc_wrap.h b/src/core/hle/kernel/svc_wrap.h index a60adfcab..d309f166c 100644 --- a/src/core/hle/kernel/svc_wrap.h +++ b/src/core/hle/kernel/svc_wrap.h @@ -669,4 +669,26 @@ void SvcWrap32(Core::System& system) { FuncReturn(system, retval); } +// Used by CreateCodeMemory32 +template +void SvcWrap32(Core::System& system) { + Handle handle = 0; + + const u32 retval = func(system, &handle, Param32(system, 1), Param32(system, 2)).raw; + + system.CurrentArmInterface().SetReg(1, handle); + FuncReturn(system, retval); +} + +// Used by ControlCodeMemory32 +template +void SvcWrap32(Core::System& system) { + const u32 retval = + func(system, Param32(system, 0), Param32(system, 1), Param(system, 2), Param(system, 4), + static_cast(Param32(system, 6))) + .raw; + + FuncReturn(system, retval); +} + } // namespace Kernel -- cgit v1.2.3