Merge pull request #2509 from Cacodemon345/replycirrus

Add Reply Video Adapter for MCA (Cirrus CL-GD5426)
This commit is contained in:
Miran Grča
2022-07-26 15:12:01 +02:00
committed by GitHub
3 changed files with 27 additions and 2 deletions

View File

@@ -329,6 +329,7 @@ extern const device_t gd5428_isa_device;
extern const device_t gd5428_vlb_device;
extern const device_t gd5428_diamond_speedstar_pro_b1_vlb_device;
extern const device_t gd5428_mca_device;
extern const device_t gd5426_mca_device;
extern const device_t gd5428_onboard_device;
extern const device_t gd5429_isa_device;
extern const device_t gd5429_vlb_device;

View File

@@ -46,6 +46,7 @@
#define BIOS_GD5420_PATH "roms/video/cirruslogic/5420.vbi"
#define BIOS_GD5422_PATH "roms/video/cirruslogic/cl5422.bin"
#define BIOS_GD5426_DIAMOND_A1_ISA_PATH "roms/video/cirruslogic/diamond5426.vbi"
#define BIOS_GD5426_MCA_PATH "roms/video/cirruslogic/Reply.BIN"
#define BIOS_GD5428_DIAMOND_B1_VLB_PATH "roms/video/cirruslogic/Diamond SpeedStar PRO VLB v3.04.bin"
#define BIOS_GD5428_ISA_PATH "roms/video/cirruslogic/5428.bin"
#define BIOS_GD5428_MCA_PATH "roms/video/cirruslogic/SVGA141.ROM"
@@ -3902,6 +3903,8 @@ static void
else {
if (gd54xx->vlb)
romfn = BIOS_GD5428_PATH;
else if (gd54xx->mca)
romfn = BIOS_GD5426_MCA_PATH;
else
romfn = BIOS_GD5428_ISA_PATH;
}
@@ -4115,8 +4118,8 @@ static void
gd54xx->unlocked = 1;
if (gd54xx->mca) {
gd54xx->pos_regs[0] = 0x7b;
gd54xx->pos_regs[1] = 0x91;
gd54xx->pos_regs[0] = svga->crtc[0x27] == CIRRUS_ID_CLGD5426 ? 0x82 : 0x7b;
gd54xx->pos_regs[1] = svga->crtc[0x27] == CIRRUS_ID_CLGD5426 ? 0x81 : 0x91;
mca_add(gd5428_mca_read, gd5428_mca_write, gd5428_mca_feedb, NULL, gd54xx);
io_sethandler(0x46e8, 0x0001, gd54xx_in, NULL, NULL, gd54xx_out, NULL, NULL, gd54xx);
}
@@ -4184,6 +4187,12 @@ gd5428_isa_available(void)
return rom_present(BIOS_GD5428_ISA_PATH);
}
static int
gd5426_mca_available(void)
{
return rom_present(BIOS_GD5426_MCA_PATH);
}
static int
gd5428_mca_available(void)
{
@@ -4699,6 +4708,20 @@ const device_t gd5428_mca_device = {
.config = NULL
};
const device_t gd5426_mca_device = {
.name = "Cirrus Logic GD5426 (MCA) (Reply Video Adapter)",
.internal_name = "replymcasvga",
.flags = DEVICE_MCA,
.local = CIRRUS_ID_CLGD5426,
.init = gd54xx_init,
.close = gd54xx_close,
.reset = gd54xx_reset,
{ .available = gd5426_mca_available },
.speed_changed = gd54xx_speed_changed,
.force_redraw = gd54xx_force_redraw,
.config = gd5426_config
};
const device_t gd5428_onboard_device = {
.name = "Cirrus Logic GD5428 (ISA) (On-Board)",
.internal_name = "cl_gd5428_onboard",

View File

@@ -148,6 +148,7 @@ video_cards[] = {
{ &vga_device },
{ &v7_vga_1024i_device },
{ &wy700_device },
{ &gd5426_mca_device },
{ &gd5428_mca_device },
{ &et4000_mca_device },
{ &radius_svga_multiview_mca_device },