mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2025-05-14 07:04:24 -04:00
kern: implement SvcDebugActiveProcess, svcGetDebugEvent, SvcWaitProcessWideKeyAtomic
This commit is contained in:
parent
1c5b58ce66
commit
36eb78a3ce
17 changed files with 728 additions and 24 deletions
|
@ -451,6 +451,33 @@ namespace ams::kern {
|
|||
return ResultSuccess();
|
||||
}
|
||||
|
||||
KProcess::State KProcess::SetDebugObject(void *debug_object) {
|
||||
/* Cache our state to return it to the debug object. */
|
||||
const auto old_state = this->state;
|
||||
|
||||
/* Set the object. */
|
||||
this->attached_object = debug_object;
|
||||
|
||||
/* Update our state. */
|
||||
if (this->state != State_DebugBreak) {
|
||||
this->state = (this->state != State_Created) ? State_DebugBreak : State_CreatedAttached;
|
||||
|
||||
/* Signal. */
|
||||
this->is_signaled = true;
|
||||
this->NotifyAvailable();
|
||||
}
|
||||
|
||||
return old_state;
|
||||
}
|
||||
|
||||
KEventInfo *KProcess::GetJitDebugInfo() {
|
||||
if (this->is_jit_debug) {
|
||||
return KDebugBase::CreateDebugEvent(this->jit_debug_event_type, this->jit_debug_exception_type, this->jit_debug_params[0], this->jit_debug_params[1], this->jit_debug_params[2], this->jit_debug_params[3], this->jit_debug_thread_id);
|
||||
} else {
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
void KProcess::SetPreemptionState() {
|
||||
MESOSPHERE_UNIMPLEMENTED();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue