aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.HLE/HOS/Kernel/KernelTransfer.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Ryujinx.HLE/HOS/Kernel/KernelTransfer.cs')
-rw-r--r--Ryujinx.HLE/HOS/Kernel/KernelTransfer.cs71
1 files changed, 0 insertions, 71 deletions
diff --git a/Ryujinx.HLE/HOS/Kernel/KernelTransfer.cs b/Ryujinx.HLE/HOS/Kernel/KernelTransfer.cs
deleted file mode 100644
index c0ce72c0..00000000
--- a/Ryujinx.HLE/HOS/Kernel/KernelTransfer.cs
+++ /dev/null
@@ -1,71 +0,0 @@
-using ChocolArm64.Memory;
-
-namespace Ryujinx.HLE.HOS.Kernel
-{
- static class KernelTransfer
- {
- public static bool UserToKernelInt32(Horizon system, long address, out int value)
- {
- KProcess currentProcess = system.Scheduler.GetCurrentProcess();
-
- if (currentProcess.CpuMemory.IsMapped(address) &&
- currentProcess.CpuMemory.IsMapped(address + 3))
- {
- value = currentProcess.CpuMemory.ReadInt32(address);
-
- return true;
- }
-
- value = 0;
-
- return false;
- }
-
- public static bool UserToKernelString(Horizon system, long address, int size, out string value)
- {
- KProcess currentProcess = system.Scheduler.GetCurrentProcess();
-
- if (currentProcess.CpuMemory.IsMapped(address) &&
- currentProcess.CpuMemory.IsMapped(address + size - 1))
- {
- value = MemoryHelper.ReadAsciiString(currentProcess.CpuMemory, address, size);
-
- return true;
- }
-
- value = null;
-
- return false;
- }
-
- public static bool KernelToUserInt32(Horizon system, long address, int value)
- {
- KProcess currentProcess = system.Scheduler.GetCurrentProcess();
-
- if (currentProcess.CpuMemory.IsMapped(address) &&
- currentProcess.CpuMemory.IsMapped(address + 3))
- {
- currentProcess.CpuMemory.WriteInt32ToSharedAddr(address, value);
-
- return true;
- }
-
- return false;
- }
-
- public static bool KernelToUserInt64(Horizon system, long address, long value)
- {
- KProcess currentProcess = system.Scheduler.GetCurrentProcess();
-
- if (currentProcess.CpuMemory.IsMapped(address) &&
- currentProcess.CpuMemory.IsMapped(address + 7))
- {
- currentProcess.CpuMemory.WriteInt64(address, value);
-
- return true;
- }
-
- return false;
- }
- }
-} \ No newline at end of file