|
|
@@ -42,15 +42,12 @@ namespace Ryujinx.HLE.HOS.Services
|
|
|
public string Name { get; }
|
|
|
public Func<IpcService> SmObjectFactory { get; }
|
|
|
|
|
|
- private int _threadCount;
|
|
|
-
|
|
|
- public ServerBase(KernelContext context, string name, Func<IpcService> smObjectFactory = null, int threadCount = 1)
|
|
|
+ public ServerBase(KernelContext context, string name, Func<IpcService> smObjectFactory = null)
|
|
|
{
|
|
|
InitDone = new ManualResetEvent(false);
|
|
|
_context = context;
|
|
|
Name = name;
|
|
|
SmObjectFactory = smObjectFactory;
|
|
|
- _threadCount = threadCount;
|
|
|
|
|
|
const ProcessCreationFlags flags =
|
|
|
ProcessCreationFlags.EnableAslr |
|
|
|
@@ -86,27 +83,6 @@ namespace Ryujinx.HLE.HOS.Services
|
|
|
|
|
|
private void Main()
|
|
|
{
|
|
|
- for (int i = 1; i < _threadCount; i++)
|
|
|
- {
|
|
|
- KernelResult result = _context.Syscall.CreateThread(out int threadHandle, 0UL, 0UL, 0UL, 44, 3, ServerLoop);
|
|
|
-
|
|
|
- if (result == KernelResult.Success)
|
|
|
- {
|
|
|
- result = _context.Syscall.StartThread(threadHandle);
|
|
|
-
|
|
|
- if (result != KernelResult.Success)
|
|
|
- {
|
|
|
- Logger.Error?.Print(LogClass.Service, $"Failed to start thread on {Name}: {result}");
|
|
|
- }
|
|
|
-
|
|
|
- _context.Syscall.CloseHandle(threadHandle);
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- Logger.Error?.Print(LogClass.Service, $"Failed to create thread on {Name}: {result}");
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
ServerLoop();
|
|
|
}
|
|
|
|