Automatic FINTR's on failed / zero-step seeks and recalibrates now also disable the timer, fixes booting floppies on Intel AMI BIOS'es.

This commit is contained in:
OBattler
2020-06-18 00:29:36 +02:00
parent 1f5933d4df
commit 8e4757513f

View File

@@ -93,6 +93,7 @@ int floppyrate[4];
int fdc_type = 0; int fdc_type = 0;
#define ENABLE_FDC_LOG 1
#ifdef ENABLE_FDC_LOG #ifdef ENABLE_FDC_LOG
int fdc_do_log = ENABLE_FDC_LOG; int fdc_do_log = ENABLE_FDC_LOG;
@@ -1121,6 +1122,7 @@ fdc_write(uint16_t addr, uint8_t val, void *priv)
fdc->fintr = 1; fdc->fintr = 1;
fdc->interrupt = -4; fdc->interrupt = -4;
} else { } else {
timer_disable(&fdc->timer);
fdc->interrupt = -3; fdc->interrupt = -3;
fdc_callback(fdc); fdc_callback(fdc);
} }
@@ -1184,6 +1186,7 @@ fdc_write(uint16_t addr, uint8_t val, void *priv)
fdc->fintr = 1; fdc->fintr = 1;
fdc->interrupt = -4; fdc->interrupt = -4;
} else { } else {
timer_disable(&fdc->timer);
fdc->interrupt = -3; fdc->interrupt = -3;
fdc_callback(fdc); fdc_callback(fdc);
} }
@@ -1209,6 +1212,7 @@ fdc_write(uint16_t addr, uint8_t val, void *priv)
fdc->fintr = 1; fdc->fintr = 1;
fdc->interrupt = -4; fdc->interrupt = -4;
} else { } else {
timer_disable(&fdc->timer);
fdc->interrupt = -3; fdc->interrupt = -3;
fdc_callback(fdc); fdc_callback(fdc);
} }
@@ -1223,6 +1227,7 @@ fdc_write(uint16_t addr, uint8_t val, void *priv)
fdc->fintr = 1; fdc->fintr = 1;
fdc->interrupt = -4; fdc->interrupt = -4;
} else { } else {
timer_disable(&fdc->timer);
fdc->interrupt = -3; fdc->interrupt = -3;
fdc_callback(fdc); fdc_callback(fdc);
} }