Merge pull request #6449 from rushieda/ms6318

Add the MSI MS-6318 and its OEM variants
This commit is contained in:
Miran Grča
2025-11-08 02:19:22 +01:00
committed by GitHub
3 changed files with 204 additions and 0 deletions

View File

@@ -1302,6 +1302,10 @@ extern int machine_at_p6bap_init(const machine_t *);
/* VIA Apollo Pro 133A */
extern int machine_at_6via90ap_init(const machine_t *);
extern int machine_at_cuv4xls_init(const machine_t *);
#ifdef EMU_DEVICE_H
extern const device_t ms6318_device;
#endif
extern int machine_at_ms6318_init(const machine_t *);
/* SiS 600 */
extern int machine_at_7sbb_init(const machine_t *);

View File

@@ -434,6 +434,161 @@ machine_at_cuv4xls_init(const machine_t *model)
return ret;
}
static const device_config_t ms6318_config[] = {
// clang-format off
{
.name = "bios",
.description = "BIOS Version",
.type = CONFIG_BIOS,
.default_string = "ms6318",
.default_int = 0,
.file_filter = NULL,
.spinner = { 0 },
.selection = { { 0 } },
.bios = {
{
.name = "Award Modular BIOS v6.00PG - Revision 1.1",
.internal_name = "ms6318_110",
.bios_type = BIOS_NORMAL,
.files_no = 1,
.local = 0,
.size = 262144,
.files = { "roms/machines/ms6318/w6318vms.110", "" }
},
{
.name = "Award Modular BIOS v6.00PG - Revision 1.2",
.internal_name = "ms6318",
.bios_type = BIOS_NORMAL,
.files_no = 1,
.local = 0,
.size = 262144,
.files = { "roms/machines/ms6318/w6318vms.120", "" }
},
{
.name = "Award Modular BIOS v6.00PG - Revision 7.1B5E (Elonex OEM)",
.internal_name = "ms6318_715",
.bios_type = BIOS_NORMAL,
.files_no = 1,
.local = 0,
.size = 262144,
.files = { "roms/machines/ms6318/w6318ve1.715", "" }
},
{
.name = "Award Modular BIOS v6.00PG - Revision 1.0B9 (Fujitsu-Siemens OEM)",
.internal_name = "ms6318_109",
.bios_type = BIOS_NORMAL,
.files_no = 1,
.local = 0,
.size = 262144,
.files = { "roms/machines/ms6318/ms-6318-ver5.bin", "" }
},
{
.name = "Award Modular BIOS v6.00PG - Revision 1.8 (HP OEM)",
.internal_name = "ms6318_180",
.bios_type = BIOS_NORMAL,
.files_no = 1,
.local = 0,
.size = 262144,
.files = { "roms/machines/ms6318/med2000v2.bin", "" }
},
{
.name = "Award Modular BIOS v6.00PG - Revision 1.9 (HP OEM)",
.internal_name = "ms6318_190",
.bios_type = BIOS_NORMAL,
.files_no = 1,
.local = 0,
.size = 262144,
.files = { "roms/machines/ms6318/med2000.bin", "" }
},
{
.name = "Award Modular BIOS v6.00PG - Revision 2.02 (HP OEM)",
.internal_name = "ms6318_202",
.bios_type = BIOS_NORMAL,
.files_no = 1,
.local = 0,
.size = 262144,
.files = { "roms/machines/ms6318/ms6318hp.bin", "" }
},
{
.name = "Award Modular BIOS v6.00PG - Revision 1.3 (Medion OEM)",
.internal_name = "ms6318_130",
.bios_type = BIOS_NORMAL,
.files_no = 1,
.local = 0,
.size = 262144,
.files = { "roms/machines/ms6318/ms6318.bin", "" }
},
{
.name = "Award Modular BIOS v6.00PG - Revision 7.51 (Medion OEM)",
.internal_name = "ms6318_751",
.bios_type = BIOS_NORMAL,
.files_no = 1,
.local = 0,
.size = 262144,
.files = { "roms/machines/ms6318/bios.rom", "" }
},
{ .files_no = 0 }
}
},
{ .name = "", .description = "", .type = CONFIG_END }
// clang-format on
};
const device_t ms6318_device = {
.name = "MSI MS-6318",
.internal_name = "ms6318_device",
.flags = 0,
.local = 0,
.init = NULL,
.close = NULL,
.reset = NULL,
.available = NULL,
.speed_changed = NULL,
.force_redraw = NULL,
.config = ms6318_config
};
int
machine_at_ms6318_init(const machine_t *model)
{
int ret = 0;
const char *fn;
/* No ROMs available */
if (!device_available(model->device))
return ret;
device_context(model->device);
fn = device_get_bios_file(machine_get_device(machine), device_get_config_bios("bios"), 0);
ret = bios_load_linear(fn, 0x000c0000, 262144, 0);
device_context_restore();
machine_at_common_init_ex(model, 2);
pci_init(PCI_CONFIG_TYPE_1);
pci_register_slot(0x00, PCI_CARD_NORTHBRIDGE, 0, 0, 0, 0);
pci_register_slot(0x07, PCI_CARD_SOUTHBRIDGE, 1, 2, 3, 4);
pci_register_slot(0x0C, PCI_CARD_SOUND, 3, 4, 1, 2);
pci_register_slot(0x0E, PCI_CARD_NORMAL, 1, 2, 3, 4);
pci_register_slot(0x0F, PCI_CARD_NORMAL, 2, 3, 4, 1);
pci_register_slot(0x10, PCI_CARD_NORMAL, 3, 4, 1, 2);
pci_register_slot(0x01, PCI_CARD_AGPBRIDGE, 1, 2, 3, 4);
device_add(&via_apro133a_device);
device_add(&via_vt82c686b_device); /* fans: CPU1, CPU2; temperatures: CPU, System, unused */
device_add(&sst_flash_39sf020_device); /* assumed */
spd_register(SPD_TYPE_SDRAM, 0x7, 1024);
hwm_values.temperatures[0] += 2; /* CPU offset */
hwm_values.temperatures[1] += 2; /* System offset */
hwm_values.temperatures[2] = 0; /* unused */
if (sound_card_current[0] == SOUND_INTERNAL)
device_add(machine_get_snd_device(machine));
device_add(&stac9708_device);
return ret;
}
/* SiS 600 */
int
machine_at_7sbb_init(const machine_t *model)

View File

@@ -19821,6 +19821,51 @@ const machine_t machines[] = {
.snd_device = &cmi8738_onboard_device,
.net_device = NULL
},
/* Has the VIA VT82C686B southbridge with on-chip KBC identical to the VIA
VT82C42N. */
{
.name = "[VIA Apollo Pro 133A] MSI MS-6318",
.internal_name = "ms6318",
.type = MACHINE_TYPE_SOCKET370,
.chipset = MACHINE_CHIPSET_VIA_APOLLO_PRO_133A,
.init = machine_at_ms6318_init,
.p1_handler = machine_generic_p1_handler,
.gpio_handler = NULL,
.available_flag = MACHINE_AVAILABLE,
.gpio_acpi_handler = NULL,
.cpu = {
.package = CPU_PKG_SOCKET370,
.block = CPU_BLOCK_NONE,
.min_bus = 66666667,
.max_bus = 150000000,
.min_voltage = 1300,
.max_voltage = 3500,
.min_multi = MACHINE_MULTIPLIER_FIXED,
.max_multi = MACHINE_MULTIPLIER_FIXED
},
.bus_flags = MACHINE_PS2_A97 | MACHINE_BUS_USB,
.flags = MACHINE_IDE_DUAL | MACHINE_AG | MACHINE_APM | MACHINE_ACPI | MACHINE_GAMEPORT | MACHINE_USB,
.ram = {
.min = 16384,
.max = 2097152,
.step = 8192
},
.nvrmask = 255,
.jumpered_ecp_dma = 0,
.default_jumpered_ecp_dma = -1,
.kbc_device = NULL,
.kbc_params = 0x00000000,
.kbc_p1 = 0x00000cf0,
.gpio = 0xffffffff,
.gpio_acpi = 0xffffffff,
.device = &ms6318_device,
.kbd_device = NULL,
.fdc_device = NULL,
.sio_device = NULL,
.vid_device = NULL,
.snd_device = &ct5880_onboard_device,
.net_device = NULL
},
/* Miscellaneous/Fake/Hypervisor machines */
/* Has a Winbond W83977F Super I/O chip with on-chip KBC with AMIKey-2 KBC