More correct implementation of the FDC FIFO.

This commit is contained in:
OBattler
2021-09-17 02:18:23 +02:00
parent b57c22df66
commit ef6d3d01db
2 changed files with 48 additions and 23 deletions

View File

@@ -1577,7 +1577,7 @@ d86f_read_sector_data(int drive, int side)
} else {
if (dev->data_find.bytes_obtained < d86f_get_data_len(drive)) {
if (dev->state != STATE_16_VERIFY_DATA) {
read_status = fdc_data(d86f_fdc, data);
read_status = fdc_data(d86f_fdc, data, dev->data_find.bytes_obtained == ((d86f_get_data_len(drive)) - 1));
if (read_status == -1)
dev->dma_over++;
}
@@ -2139,7 +2139,7 @@ d86f_turbo_read(int drive, int side)
} else {
if (dev->data_find.bytes_obtained < (128UL << dev->last_sector.id.n)) {
if (dev->state != STATE_16_VERIFY_DATA) {
read_status = fdc_data(d86f_fdc, dat);
read_status = fdc_data(d86f_fdc, dat, dev->data_find.bytes_obtained == ((128UL << dev->last_sector.id.n) - 1));
if (read_status == -1)
dev->dma_over++;
}