From: Toni Wilen Date: Sat, 17 Mar 2018 14:05:08 +0000 (+0200) Subject: 5380 DRQ bit stays active until DMA is disabled. (FastTrak needs this) X-Git-Tag: 4000~146 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=9926b156aef625e0240e90f789cf421c321b23de;p=francis%2Fwinuae.git 5380 DRQ bit stays active until DMA is disabled. (FastTrak needs this) --- diff --git a/scsi.cpp b/scsi.cpp index e87f9f54..c783f3ce 100644 --- a/scsi.cpp +++ b/scsi.cpp @@ -821,6 +821,7 @@ struct soft_scsi bool dma_active; bool dma_started; bool dma_controller; + bool dma_drq; struct romconfig *rc; struct soft_scsi **self_ptr; @@ -1850,7 +1851,8 @@ uae_u8 ncr5380_bget(struct soft_scsi *scsi, int reg) if (scsi->irq) { v |= 1 << 4; } - if (scsi->dma_active && !scsi->dma_controller && r->bus_phase == (scsi->regs[3] & 7)) { + if (scsi->dma_drq || (scsi->dma_active && !scsi->dma_controller && r->bus_phase == (scsi->regs[3] & 7))) { + scsi->dma_drq = true; v |= 1 << 6; } if (scsi->regs[2] & 4) { @@ -1942,6 +1944,7 @@ void ncr5380_bput(struct soft_scsi *scsi, int reg, uae_u8 v) scsi->regs[5] &= ~(0x80 | 0x40); scsi->dma_direction = 0; scsi->dma_active = false; + scsi->dma_drq = false; } break; case 5: