| 142 | } |
| 143 | |
| 144 | inline void SITransferNext(s32 chan) |
| 145 | { |
| 146 | int i; |
| 147 | SIPacket* packet; |
| 148 | |
| 149 | for (i = 0; i < SI_MAX_CHAN; ++i) |
| 150 | { |
| 151 | ++chan; |
| 152 | chan %= SI_MAX_CHAN; |
| 153 | packet = &Packet[chan]; |
| 154 | if (packet->chan != -1 && packet->fire <= __OSGetSystemTime()) |
| 155 | { |
| 156 | if (__SITransfer(packet->chan, packet->output, packet->outputBytes, packet->input, |
| 157 | packet->inputBytes, packet->callback)) |
| 158 | { |
| 159 | OSCancelAlarm(&Alarm[chan]); |
| 160 | packet->chan = -1; |
| 161 | } |
| 162 | break; |
| 163 | } |
| 164 | } |
| 165 | } |
| 166 | |
| 167 | static void SIInterruptHandler(__OSInterrupt interrupt, OSContext* context) |
| 168 | { |
no test coverage detected