From: Toni Wilen Date: Thu, 17 Nov 2022 17:50:27 +0000 (+0200) Subject: Reading from non-existing drive didn't complete active disk DMA. X-Git-Tag: 41000~75 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=754980e961fc5d0539fa1c2bbff0e7e805e75807;p=francis%2Fwinuae.git Reading from non-existing drive didn't complete active disk DMA. --- diff --git a/disk.cpp b/disk.cpp index 13a4e878..fa1dfefd 100644 --- a/disk.cpp +++ b/disk.cpp @@ -4080,14 +4080,11 @@ static void wordsync_detected(bool startup) static void disk_doupdate_read_reallynothing(int floppybits, bool state) { bool done = false; - // Only because there is at least one demo that checks wrong bit - // and hangs unless DSKSYNC bit it set with zero DSKSYNC value... - if (INTREQR() & 0x1000) - return; while (floppybits >= get_floppy_speed()) { bool skipbit = false; word <<= 1; word |= (state ? 1 : 0); + doreaddma(); // MSBSYNC if (adkcon & 0x200) { if ((word & 0x0001) == 0 && bitoffset == 0) { @@ -4103,7 +4100,9 @@ static void disk_doupdate_read_reallynothing(int floppybits, bool state) dskbytr_val = word & 0xff; dskbytr_val |= 0x8000; } - if (!done && !(adkcon & 0x200) && word == dsksync) { + // Only because there is at least one demo that checks wrong bit + // and hangs unless DSKSYNC bit it set with zero DSKSYNC value... + if (!(INTREQR() & 0x1000) && !done && !(adkcon & 0x200) && word == dsksync) { INTREQ(0x8000 | 0x1000); done = true; }