mirror of
https://github.com/stenzek/duckstation.git
synced 2024-11-26 23:50:31 +00:00
InterruptController: Masked interrupts are still set in the status register
This commit is contained in:
parent
fbd7fcec48
commit
734d1a7ee1
@ -31,7 +31,7 @@ bool InterruptController::DoState(StateWrapper& sw)
|
||||
void InterruptController::InterruptRequest(IRQ irq)
|
||||
{
|
||||
const u32 bit = (u32(1) << static_cast<u32>(irq));
|
||||
m_interrupt_status_register |= (bit & m_interrupt_mask_register);
|
||||
m_interrupt_status_register |= bit;
|
||||
UpdateCPUInterruptRequest();
|
||||
}
|
||||
|
||||
@ -81,7 +81,7 @@ void InterruptController::WriteRegister(u32 offset, u32 value)
|
||||
void InterruptController::UpdateCPUInterruptRequest()
|
||||
{
|
||||
// external interrupts set bit 10 only?
|
||||
if (m_interrupt_status_register != 0)
|
||||
if ((m_interrupt_status_register & m_interrupt_mask_register) != 0)
|
||||
m_cpu->SetExternalInterrupt(2);
|
||||
else
|
||||
m_cpu->ClearExternalInterrupt(2);
|
||||
|
Loading…
Reference in New Issue
Block a user