src/emu/cpu/z80/z80daisy.c
| r9935 | r9936 | |
| 144 | 144 | |
| 145 | 145 | int z80_daisy_chain::call_ack_device() |
| 146 | 146 | { |
| 147 | int vector = 0; |
| 148 | |
| 147 | 149 | // loop over all devices; dev[0] is the highest priority |
| 148 | 150 | for (daisy_entry *daisy = m_daisy_list; daisy != NULL; daisy = daisy->m_next) |
| 149 | 151 | { |
| 150 | 152 | // if this device is asserting the INT line, that's the one we want |
| 151 | 153 | int state = daisy->m_interface->z80daisy_irq_state(); |
| 154 | vector = daisy->m_interface->z80daisy_irq_ack(); |
| 152 | 155 | if (state & Z80_DAISY_INT) |
| 153 | | return daisy->m_interface->z80daisy_irq_ack(); |
| 156 | return vector; |
| 154 | 157 | } |
| 155 | 158 | logerror("z80daisy_call_ack_device: failed to find an device to ack!\n"); |
| 156 | | return 0; |
| 159 | return vector; |
| 157 | 160 | } |
| 158 | 161 | |
| 159 | 162 | |