mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2025-07-23 19:05:45 +00:00
timing: wait for completion on unregister
This commit is contained in:
parent
c45b1d8723
commit
e1b0b3d0db
3 changed files with 27 additions and 28 deletions
|
@ -18,7 +18,8 @@ void KHardwareTimer::Initialize() {
|
|||
}
|
||||
|
||||
void KHardwareTimer::Finalize() {
|
||||
this->DisableInterrupt();
|
||||
m_kernel.System().CoreTiming().UnscheduleEvent(m_event_type, reinterpret_cast<uintptr_t>(this));
|
||||
m_wakeup_time = std::numeric_limits<s64>::max();
|
||||
m_event_type.reset();
|
||||
}
|
||||
|
||||
|
@ -59,7 +60,8 @@ void KHardwareTimer::EnableInterrupt(s64 wakeup_time) {
|
|||
}
|
||||
|
||||
void KHardwareTimer::DisableInterrupt() {
|
||||
m_kernel.System().CoreTiming().UnscheduleEvent(m_event_type, reinterpret_cast<uintptr_t>(this));
|
||||
m_kernel.System().CoreTiming().UnscheduleEventWithoutWait(m_event_type,
|
||||
reinterpret_cast<uintptr_t>(this));
|
||||
m_wakeup_time = std::numeric_limits<s64>::max();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue