Commit 8bd4563
committed
nullsound: fix race when handling NMI and INT concurrently
When a Timer interrupts the current sound driver, the interrupt
handler has to save current registers. During this execution,
new interrupts are masked, but a NMI can still occur and interrupt
the interrupt handler.
To avoid losing the state of the original sound driver, one cannot
use shadow registers for both Timer and NMI handlers. Instead,
make the Timer interrupt handler save register on the stack.
Closes #1151 parent caebcc3 commit 8bd4563
2 files changed
+8
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
63 | | - | |
64 | 62 | | |
65 | | - | |
66 | | - | |
67 | 63 | | |
68 | 64 | | |
69 | 65 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
63 | 67 | | |
| 68 | + | |
| 69 | + | |
64 | 70 | | |
65 | 71 | | |
66 | 72 | | |
| |||
89 | 95 | | |
90 | 96 | | |
91 | 97 | | |
| 98 | + | |
| 99 | + | |
92 | 100 | | |
93 | 101 | | |
94 | 102 | | |
| |||
0 commit comments