IDE updates, fix mouse hook hotkey

Added support for headerless (RDSK) HDD images, and fixed the IDE controller emulation to not keep separate LBA1-4 values for each hard drive.
This may look strange at first glance, but the Amiga would regularly write the CHS values for drive access ahead of actually switching to the drive it wanted, so I assume this is how it's actually supposed to work.
The second drive still doesn't mount automatically on boot, but I believe that some currently unsupported register write or read is causing this.
This commit is contained in:
beeanyew
2021-01-15 04:30:52 +01:00
parent 29a3773323
commit c6b96c6d73
8 changed files with 180 additions and 50 deletions

View File

@@ -377,7 +377,7 @@ inline void gpio_handle_irq() {
srdata = read_reg();
m68k_set_irq((srdata >> 13) & 0xff);
} else {
if ((gayle_int & 0x80) && get_ide(0)->drive->intrq) {
if ((gayle_int & 0x80) && (get_ide(0)->drive[0].intrq || get_ide(0)->drive[1].intrq)) {
write16(0xdff09c, 0x8008);
m68k_set_irq(2);
}

View File

@@ -76,7 +76,7 @@
srdata = read_reg(); \
m68k_set_irq((srdata >> 13) & 0xff); \
} else { \
if ((gayle_int & 0x80) && get_ide(0)->drive->intrq) { \
if ((gayle_int & 0x80) && (get_ide(0)->drive[0].intrq || get_ide(0)->drive[1].intrq)) { \
write16(0xdff09c, 0x8008); \
m68k_set_irq(2); \
} \