SCSI CD-ROM fixes of the day.

1.Re-implemented in the best way possible the muted part of the Toshiba/NEC Play Audio commands and related, per spec.
2. Forgot to add a check to a Sony Vendor Data Out command  when the len is 0 it should become a Status command, fixes emulator crashes when len is 0 using some CD software.
This commit is contained in:
TC1995
2024-02-06 21:18:25 +01:00
parent 681128fc9c
commit 0d88e8394c
3 changed files with 33 additions and 16 deletions

View File

@@ -3613,6 +3613,14 @@ atapi_out:
dev->sony_vendor = 1;
len = (cdb[7] << 8) | cdb[8];
if (!len) {
scsi_cdrom_set_phase(dev, SCSI_PHASE_STATUS);
scsi_cdrom_log("CD-ROM %i: PlayBack Control Sony All done - callback set\n", dev->id);
dev->packet_status = PHASE_COMPLETE;
dev->callback = 20.0 * CDROM_TIME;
scsi_cdrom_set_callback(dev);
break;
}
scsi_cdrom_buf_alloc(dev, 65536);
scsi_cdrom_set_buf_len(dev, BufLen, &len);