diff options
author | Mary <mary@mary.zone> | 2023-06-20 17:33:54 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-20 17:33:54 +0200 |
commit | 649d372f7da8559f8b6d74ca44af64ba7d7853c4 (patch) | |
tree | 813e6af65602b4c1138a36bd8c214b0dd228ba60 /src/Ryujinx.HLE/HOS/ArmProcessContext.cs | |
parent | f9a538bb0f02b4665f8cccbde0730e08da208024 (diff) |
misc: Implement address space size workarounds (#5191)1.1.898
* misc: Implement address space size workarounds
This adds code to support userland with less than 39 bits of address
space available by testing reserving multiple sizes and reducing
guess address space when needed.
This is required for ARM64 support when the kernel is
configured to use 63..39 bits for kernel space.(meaning only 38 bits is available to userland)
* Address comments
* Fix 32 bits address space support and address more comments
Diffstat (limited to 'src/Ryujinx.HLE/HOS/ArmProcessContext.cs')
-rw-r--r-- | src/Ryujinx.HLE/HOS/ArmProcessContext.cs | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/Ryujinx.HLE/HOS/ArmProcessContext.cs b/src/Ryujinx.HLE/HOS/ArmProcessContext.cs index 6338edc1..99b35528 100644 --- a/src/Ryujinx.HLE/HOS/ArmProcessContext.cs +++ b/src/Ryujinx.HLE/HOS/ArmProcessContext.cs @@ -25,7 +25,15 @@ namespace Ryujinx.HLE.HOS public IVirtualMemoryManager AddressSpace => _memoryManager; - public ArmProcessContext(ulong pid, ICpuEngine cpuEngine, GpuContext gpuContext, T memoryManager, bool for64Bit) + public ulong AddressSpaceSize { get; } + + public ArmProcessContext( + ulong pid, + ICpuEngine cpuEngine, + GpuContext gpuContext, + T memoryManager, + ulong addressSpaceSize, + bool for64Bit) { if (memoryManager is IRefCounted rc) { @@ -38,6 +46,8 @@ namespace Ryujinx.HLE.HOS _gpuContext = gpuContext; _cpuContext = cpuEngine.CreateCpuContext(memoryManager, for64Bit); _memoryManager = memoryManager; + + AddressSpaceSize = addressSpaceSize; } public IExecutionContext CreateExecutionContext(ExceptionCallbacks exceptionCallbacks) |