From 7d6e60d4b8177f6aa1424eb108e821916ab59698 Mon Sep 17 00:00:00 2001 From: OBattler Date: Fri, 21 Sep 2018 00:39:42 +0200 Subject: [PATCH] Fixed the S3 ViRGE new MMIO mapping; Ported over the September 17th PCem ATi Korean VGA patch from greatpsycho. --- src/video/vid_ati28800.c | 6 +++--- src/video/vid_s3_virge.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/video/vid_ati28800.c b/src/video/vid_ati28800.c index 1bc2d50a8..edecc80ed 100644 --- a/src/video/vid_ati28800.c +++ b/src/video/vid_ati28800.c @@ -8,7 +8,7 @@ * * ATI 28800 emulation (VGA Charger and Korean VGA) * - * Version: @(#)vid_ati28800.c 1.0.22 2018/09/19 + * Version: @(#)vid_ati28800.c 1.0.23 2018/09/21 * * Authors: Sarah Walker, * Miran Grca, @@ -234,7 +234,7 @@ void ati28800k_out(uint16_t addr, uint8_t val, void *p) break; case 0x3DE: ati28800->in_get_korean_font_kind_set = 0; - if(ati28800->get_korean_font_enabled && (ati28800->regs[0xBF] & 0x20)) + if(ati28800->get_korean_font_enabled) { if((ati28800->get_korean_font_base & 0x7F) > 0x20 && (ati28800->get_korean_font_base & 0x7F) < 0x7F) fontdatksc5601_user[(ati28800->get_korean_font_kind & 4) * 24 + (ati28800->get_korean_font_base & 0x7F) - 0x20].chr[ati28800->get_korean_font_index] = val; @@ -348,7 +348,7 @@ uint8_t ati28800k_in(uint16_t addr, void *p) switch (addr) { case 0x3DE: - if (ati28800->get_korean_font_enabled && (ati28800->regs[0xBF] & 0x20)) + if (ati28800->get_korean_font_enabled) { switch(ati28800->get_korean_font_kind >> 8) { diff --git a/src/video/vid_s3_virge.c b/src/video/vid_s3_virge.c index 64375bb2a..ce8efffb5 100644 --- a/src/video/vid_s3_virge.c +++ b/src/video/vid_s3_virge.c @@ -8,7 +8,7 @@ * * S3 ViRGE emulation. * - * Version: @(#)vid_s3_virge.c 1.0.14 2018/09/20 + * Version: @(#)vid_s3_virge.c 1.0.15 2018/09/21 * * Authors: Sarah Walker, * Miran Grca, @@ -777,7 +777,7 @@ static void s3_virge_updatemapping(virge_t *virge) mem_mapping_disable(&virge->mmio_mapping); /* New MMIO. */ - if ((svga->crtc[0x53] & 0x18) == 0x18) /*New MMIO*/ + if (svga->crtc[0x53] & 0x08) /*New MMIO*/ mem_mapping_set_addr(&virge->new_mmio_mapping, virge->linear_base + 0x1000000, 0x10000); else mem_mapping_disable(&virge->new_mmio_mapping);