From e014dc4ee1a3b5ea97b63d079ce098faecf4d72d Mon Sep 17 00:00:00 2001 From: BurnedPinguin Date: Tue, 11 Jul 2023 14:02:02 +0200 Subject: [PATCH] Add ECS AL486 --- src/include/86box/machine.h | 1 + src/machine/m_at_386dx_486.c | 22 ++++++++++++++++++- src/machine/machine_table.c | 41 +++++++++++++++++++++++++++++++++++- 3 files changed, 62 insertions(+), 2 deletions(-) diff --git a/src/include/86box/machine.h b/src/include/86box/machine.h index 52cac6d8b..7b372836c 100644 --- a/src/include/86box/machine.h +++ b/src/include/86box/machine.h @@ -542,6 +542,7 @@ extern int machine_at_spc7700plw_init(const machine_t *); extern int machine_at_ms4134_init(const machine_t *); extern int machine_at_tg486gp_init(const machine_t *); extern int machine_at_tg486g_init(const machine_t *); +extern int machine_at_ecsal486_init(const machine_t *); /* m_at_commodore.c */ extern int machine_at_cmdpc_init(const machine_t *); diff --git a/src/machine/m_at_386dx_486.c b/src/machine/m_at_386dx_486.c index cc4345db5..479f60194 100644 --- a/src/machine/m_at_386dx_486.c +++ b/src/machine/m_at_386dx_486.c @@ -230,7 +230,7 @@ machine_at_ecs386v_init(const machine_t *model) { int ret; - ret = bios_load_linear("roms/machines/ECS_386V/PANDA_386V.BIN", + ret = bios_load_linear("roms/machines/ecs386v/PANDA_386V.BIN", 0x000f0000, 65536, 0); if (bios_only || !ret) @@ -1970,4 +1970,24 @@ machine_at_tg486g_init(const machine_t *model) return ret; } +int +machine_at_ecsal486_init(const machine_t *model) +{ + int ret; + ret = bios_load_linear("roms/machines/ecsal486/ECS_AL486.BIN", + 0x000f0000, 65536, 0); + + if (bios_only || !ret) + return ret; + + machine_at_common_init(model); + + device_add(&ali1429g_device); + device_add(&keyboard_ps2_ami_pci_device); + + if (fdc_type == FDC_INTERNAL) + device_add(&fdc_at_device); + + return ret; +} diff --git a/src/machine/machine_table.c b/src/machine/machine_table.c index 1699094d8..122e54fc8 100644 --- a/src/machine/machine_table.c +++ b/src/machine/machine_table.c @@ -4790,7 +4790,7 @@ const machine_t machines[] = { /* Has AMI Megakey P KBC firmware */ { .name = "[ALi M1429] ECS Panda 386V", - .internal_name = "ECS_386V", + .internal_name = "ecs386v", .type = MACHINE_TYPE_386DX, .chipset = MACHINE_CHIPSET_ALI_M1429, .init = machine_at_ecs386v_init, @@ -6257,6 +6257,45 @@ const machine_t machines[] = { .snd_device = NULL, .net_device = NULL }, + /* This has an AMIKey-2, which is an updated version of type 'H'. */ + { + .name = "[ALi M1429G] ECS AL486", + .internal_name = "ecsal486", + .type = MACHINE_TYPE_486_S3, + .chipset = MACHINE_CHIPSET_ALI_M1429G, + .init = machine_at_ecsal486_init, + .pad = 0, + .pad0 = 0, + .pad1 = MACHINE_AVAILABLE, + .pad2 = 0, + .cpu = { + .package = CPU_PKG_SOCKET3, + .block = CPU_BLOCK_NONE, + .min_bus = 0, + .max_bus = 0, + .min_voltage = 0, + .max_voltage = 0, + .min_multi = 0, + .max_multi = 0 + }, + .bus_flags = MACHINE_VLB, + .flags = MACHINE_APM, + .ram = { + .min = 1024, + .max = 98304, + .step = 1024 + }, + .nvrmask = 127, + .kbc_device = NULL, + .kbc_p1 = 0, + .gpio = 0, + .device = NULL, + .fdc_device = NULL, + .sio_device = NULL, + .vid_device = NULL, + .snd_device = NULL, + .net_device = NULL + }, /* 486 machines which utilize the PCI bus */ /* Machine with ALi M1429G chipset and M1435 southbridge */