River : HLE: Make process identity explicit for service metadata resolution #100
No reviewers
Labels
No labels
audio
bug
confirmed
cpu
critical
development
enhancement
gpu
graphics-backend:opengl
graphics-backend:vulkan
gui
help wanted
horizon/hle
i18n
infra
input
kernel
linux
macos
suggestion
windows
No assignees
2 participants
Notifications
Due date
No due date set.
Reference
projects/Ryubing!100
Loading…
Reference in a new issue
No description provided.
Delete branch "Babib3l/Ryubing:hle-pid-process-metadata"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This PR is the first in a batch of structural changes to Ryujinx.
Changes
ProcessIdentityandProcessKindto describe loaded programs by:ProcessResult.ProcessLoader.Processes.ActiveApplication.ClientProcessIdproperty to ServiceCtx (/src/Ryujinx.HLE/HOS/ServiceCtx.cs) that uses the handle descriptor PId when available, falling back toProcess.Pid.context.ClientProcessIdinstead ofcontext.Process.Pidfor client process access, ensuring services correctly identify the calling process even when invoked via IPC with handle descriptors.These changes make service metadata resolution more explicit and prepare the emulator for other structural changes later on.
hle-pid-process-metadatato HLE: Make process identity explicit for service metadata resolutionHLE: Make process identity explicit for service metadata resolutionto River : HLE: Make process identity explicit for service metadata resolution300001e330569988c4c9569988c4c93fbfd8bb87@ -182,7 +185,7 @@ namespace Ryujinx.HLE.HOS.Services.Am.AppletOE.ApplicationProxyService.Applicatipublic ResultCode GetDisplayVersion(ServiceCtx context){// If an NACP isn't found, the buffer will be all '\0' which seems to be the correct implementation.in c/cpp land, all strings have a null terminator, so yeah, this checks out.
@ -50,12 +50,13 @@ namespace Ryujinx.HLE.HOS.Services.Fatalprivate ResultCode ThrowFatalWithCpuContextImpl(ServiceCtx context, ResultCode resultCode, ulong pid, FatalPolicy fatalPolicy, ReadOnlySpan<byte> cpuContext){var process = context.Device.Processes.GetProcess(pid);please dont use var
@ -32,3 +32,3 @@}PlayLogQueryCapability queryCapability = (PlayLogQueryCapability)context.Device.Processes.ActiveApplication.ApplicationControlProperties.PlayLogQueryCapability;var process = context.Device.Processes.GetProcess(context.ClientProcessId);@ -87,0 +91,4 @@{if (programId == 0){return ProcessKind.Homebrew;Homebrew and games are supposed to be one and the same according to Horizon, aren't they? If that's the case, shouldn't we combine them under the same classification? I guess unless its maybe an applet, but I'm not sure I've come across that.
yep they're supposed to be the same, I changed
GetProcessKind(0)to returnProcessKind.Applicationinstead ofProcessKind.Homebrewcommit
b4bfbe026e3fbfd8bb871023e63fd7