From: Toni Wilen Date: Mon, 1 Jan 2018 17:17:28 +0000 (+0200) Subject: Comspec updates. X-Git-Tag: 3600~17 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=c370b26c37e1a95f226ff12fea86bf06c699fd90;p=francis%2Fwinuae.git Comspec updates. --- diff --git a/a2091.cpp b/a2091.cpp index 61c1b694..a0ccf0da 100644 --- a/a2091.cpp +++ b/a2091.cpp @@ -412,7 +412,7 @@ static int isirq(struct wd_state *wd) case COMSPEC_CHIP: { int irq = 0; - if ((wd->comspec.status & 0x40) && (wd->wc.auxstatus & ASR_INT)) + if ((wd->comspec.status & 0x20) && (wd->wc.auxstatus & ASR_INT)) irq |= 2; if ((wd->comspec.status & 0x08) && wd->wc.wd_data_avail) irq |= 1; @@ -1376,6 +1376,8 @@ static void wd_cmd_reset (struct wd_chip_state *wd, bool irq) if (irq) { uae_u8 status = (wd->wdregs[0] & 0x08) ? 1 : 0; set_status (wd, status, 50); + } else { + wd->wd_busy = false; } } @@ -1566,7 +1568,7 @@ void wdscsi_put (struct wd_chip_state *wd, struct wd_state *wds, uae_u8 d) write_log (_T("%s WD_DATA WRITE %02x %d/%d\n"), WD33C93, d, wd->scsi->offset, wd->scsi->data_len); #endif if (!wd->wd_data_avail) { - write_log (_T("%s WD_DATA WRITE without data request!?\n"), WD33C93); + write_log (_T("%s WD_DATA WRITE without data request!? %08x\n"), WD33C93, M68K_GETPC); return; } if (wd->wd_dataoffset < sizeof wd->wd_data) @@ -1620,7 +1622,7 @@ uae_u8 wdscsi_get (struct wd_chip_state *wd, struct wd_state *wds) v = wd->wdregs[wd->sasr]; if (wd->sasr == WD_DATA) { if (!wd->wd_data_avail) { - write_log (_T("%s WD_DATA READ without data request!?\n"), WD33C93); + write_log (_T("%s WD_DATA READ without data request!? %08x\n"), WD33C93, M68K_GETPC); return 0; } int status = scsi_receive_data(wd->scsi, &v, true); @@ -4373,7 +4375,7 @@ void cdtv_add_scsi_unit (int ch, struct uaedev_config_info *ci, struct romconfig static void comspec_ac(struct autoconfig_info *aci) { - ew(aci->autoconfig_raw, 0x00, 0xc0 | 0x01 | (aci->rc->autoboot_disabled ? 0x00: 0x10)); + ew(aci->autoconfig_raw, 0x00, 0xc0 | 0x01 | (aci->rc->subtype == 0 ? 0x00: 0x10)); ew(aci->autoconfig_raw, 0x04, 0x11); ew(aci->autoconfig_raw, 0x10, 0x03); ew(aci->autoconfig_raw, 0x14, 0xee); @@ -4440,7 +4442,7 @@ bool comspec_preinit (struct autoconfig_info *aci) rtc->yearmode = true; - if (!aci->rc->autoboot_disabled) { + if (!aci->rc->autoboot_disabled && aci->rc->subtype == 0) { map_banks(&wd->bank, 0xf00000 >> 16, 1, 0); wd->baseaddress2 = 0xf00000; } diff --git a/expansion.cpp b/expansion.cpp index f2bfeacf..abf54c20 100644 --- a/expansion.cpp +++ b/expansion.cpp @@ -1086,7 +1086,7 @@ static addrbank catweasel_bank = { ABFLAG_IO, S_READ, S_WRITE }; -static addrbank *expamem_map_catweasel (int devnum) +static addrbank *expamem_map_catweasel(struct autoconfig_info *aci) { catweasel_start = expamem_board_pointer; map_banks_z2(&catweasel_bank, catweasel_start >> 16, 1); @@ -1123,6 +1123,8 @@ static bool expamem_init_catweasel (struct autoconfig_info *aci) memcpy(aci->autoconfig_raw, expamem, sizeof aci->autoconfig_raw); + expamem_map = expamem_map_catweasel; + return true; } @@ -3958,6 +3960,17 @@ static const struct expansionsubromtype supra_sub[] = { NULL } }; +static const struct expansionsubromtype comspec_sub[] = { + { + _T("Comspec SA-1000"), _T("comspec1000"), ROMTYPE_NONE | ROMTYPE_COMSPEC, + }, + { + _T("Comspec SA-2000"), _T("comspec2000"), ROMTYPE_NONE | ROMTYPE_COMSPEC, + }, + { + NULL + } +}; static const struct expansionsubromtype mediator_sub[] = { { @@ -4753,9 +4766,9 @@ const struct expansionromtype expansionroms[] = { true, 0, a4091_settings }, { - _T("comspec1000"), _T("SA-1000"), _T("Comspec"), + _T("comspec"), _T("SA series"), _T("Comspec Communications"), comspec_preinit, comspec_init, NULL, comspec_add_scsi_unit, ROMTYPE_COMSPEC, 0, 0, BOARD_AUTOCONFIG_Z2, true, - NULL, 0, + comspec_sub, 0, true, EXPANSIONTYPE_SCSI, 0, 0, 0, false, NULL, false, 0, comspec_settings diff --git a/rommgr.cpp b/rommgr.cpp index 6d88be40..c67e17ee 100644 --- a/rommgr.cpp +++ b/rommgr.cpp @@ -531,7 +531,7 @@ static struct romdata roms[] = { 0x4fe08a5d, 0x007e5c61, 0x4048f598, 0x6d14011d, 0x23a41435, 0x5e0a2259, NULL, NULL }, { _T("M-Tec AT500 Megabody v1.33"), 1, 33, 1, 33, _T("MTECAT\0"), 32768, 199, 0, 0, ROMTYPE_MTEC, 0, 0, NULL, 0x19715a2f, 0x124f9d10, 0x19f1b285, 0x16f33f4e, 0x2bf03ca0, 0x2f9ad772, NULL, NULL }, - { _T("Comspec SA-1000 v34.805"), 34, 805, 34, 805, _T("COMSPEC\0"), 16384, 200, 0, 0, ROMTYPE_COMSPEC, 0, 0, NULL, + { _T("Comspec SA series v34.805"), 34, 805, 34, 805, _T("COMSPEC\0"), 16384, 200, 0, 0, ROMTYPE_COMSPEC, 0, 0, NULL, 0x44458e28, 0x048b8232, 0xfe54252b, 0xb81e0d06, 0x83c9e92d, 0x880f3cbf, NULL, NULL }, ALTROMPN(200, 1, 1, 8192, ROMTYPE_ODD | ROMTYPE_8BIT, NULL, 0xd5838a35, 0xb3d83657, 0x661a9fe1, 0xd54e6e69, 0xc8b13878, 0x0960a107) ALTROMPN(200, 1, 2, 8192, ROMTYPE_EVEN | ROMTYPE_8BIT, NULL, 0x098c5529, 0x6f51827d, 0x40a79438, 0x69e2d0fb, 0x6e2e46e9, 0xb65c1244)