kern: implement user thread start, el0 code now runs

This commit is contained in:
Michael Scire 2020-02-19 21:21:44 -08:00
parent 560c340c96
commit 80b115ef57
4 changed files with 16 additions and 4 deletions

View file

@ -22,7 +22,20 @@ namespace ams::kern::arch::arm64 {
void SupervisorModeThreadStarter();
void OnThreadStart() {
MESOSPHERE_TODO_IMPLEMENT();
MESOSPHERE_ASSERT(!KInterruptManager::AreInterruptsEnabled());
/* Send KDebug event for this thread's creation. */
{
KScopedInterruptEnable ei;
/* TODO */
}
/* Handle any pending dpc. */
while (GetCurrentThread().HasDpc()) {
KDpcManager::HandleDpc();
}
/* Clear our status as in an exception handler */
GetCurrentThread().ClearInExceptionHandler();
}
namespace {