Fix bad merge, and a few other fixes
This commit is contained in:
parent
ac80e7d3f9
commit
6e69cd9284
4 changed files with 14 additions and 3 deletions
|
@ -95,6 +95,11 @@ namespace Ryujinx.Core.OsHle.Handles
|
||||||
return Threads.Contains(SchedThread);
|
return Threads.Contains(SchedThread);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public bool Remove(SchedulerThread SchedThread)
|
||||||
|
{
|
||||||
|
return Threads.Remove(SchedThread);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private ConcurrentDictionary<KThread, SchedulerThread> AllThreads;
|
private ConcurrentDictionary<KThread, SchedulerThread> AllThreads;
|
||||||
|
@ -153,6 +158,11 @@ namespace Ryujinx.Core.OsHle.Handles
|
||||||
|
|
||||||
lock (SchedLock)
|
lock (SchedLock)
|
||||||
{
|
{
|
||||||
|
if (AllThreads.TryRemove(Thread, out SchedulerThread SchedThread))
|
||||||
|
{
|
||||||
|
WaitingToRun[Thread.ProcessorId].Remove(SchedThread);
|
||||||
|
}
|
||||||
|
|
||||||
SchedulerThread NewThread = WaitingToRun[Thread.ProcessorId].Pop();
|
SchedulerThread NewThread = WaitingToRun[Thread.ProcessorId].Pop();
|
||||||
|
|
||||||
if (NewThread == null)
|
if (NewThread == null)
|
||||||
|
|
|
@ -179,6 +179,8 @@ namespace Ryujinx.Core.OsHle
|
||||||
}
|
}
|
||||||
|
|
||||||
VsyncEvent.Dispose();
|
VsyncEvent.Dispose();
|
||||||
|
|
||||||
|
Scheduler.Dispose();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -370,8 +370,6 @@ namespace Ryujinx.Core.OsHle
|
||||||
INvDrvServices.NvMapsById.DeleteProcess(this);
|
INvDrvServices.NvMapsById.DeleteProcess(this);
|
||||||
INvDrvServices.NvMapsFb .DeleteProcess(this);
|
INvDrvServices.NvMapsFb .DeleteProcess(this);
|
||||||
|
|
||||||
Scheduler.Dispose();
|
|
||||||
|
|
||||||
AppletState.Dispose();
|
AppletState.Dispose();
|
||||||
|
|
||||||
SvcHandler.Dispose();
|
SvcHandler.Dispose();
|
||||||
|
|
|
@ -25,8 +25,9 @@ namespace Ryujinx.Core.OsHle.Services.Aud
|
||||||
};
|
};
|
||||||
|
|
||||||
SystemEvent = new KEvent();
|
SystemEvent = new KEvent();
|
||||||
|
|
||||||
//TODO: We shouldn't be signaling this here.
|
//TODO: We shouldn't be signaling this here.
|
||||||
SystemEvent.Handle.Set();
|
SystemEvent.WaitEvent.Set();
|
||||||
}
|
}
|
||||||
|
|
||||||
public long ListAudioDeviceName(ServiceCtx Context)
|
public long ListAudioDeviceName(ServiceCtx Context)
|
||||||
|
|
Loading…
Reference in a new issue