Merge remote-tracking branch 'origin/master' into version/4.2
This commit is contained in:
@@ -1733,6 +1733,9 @@ acpi_reg_write_sis_5595(int size, uint16_t addr, uint8_t val, void *priv)
|
|||||||
break;
|
break;
|
||||||
case 0x1c:
|
case 0x1c:
|
||||||
dev->regs.gpe_pin = ((dev->regs.gpe_pin & ~(0xff << shift32)) | ((val & 0xff) << shift32));
|
dev->regs.gpe_pin = ((dev->regs.gpe_pin & ~(0xff << shift32)) | ((val & 0xff) << shift32));
|
||||||
|
if (!strcmp(machine_get_internal_name(), "m747") && (val & 0x10) &&
|
||||||
|
!(dev->regs.gpe_io & 0x00000010))
|
||||||
|
resetx86();
|
||||||
break;
|
break;
|
||||||
case 0x1d:
|
case 0x1d:
|
||||||
dev->regs.gpe_pin = ((dev->regs.gpe_pin & ~(0x0f << shift32)) | ((val & 0x0f) << shift32));
|
dev->regs.gpe_pin = ((dev->regs.gpe_pin & ~(0x0f << shift32)) | ((val & 0x0f) << shift32));
|
||||||
|
|||||||
@@ -86,6 +86,7 @@ typedef struct sis_5513_pci_to_isa_t {
|
|||||||
port_92_t *port_92;
|
port_92_t *port_92;
|
||||||
void *pit;
|
void *pit;
|
||||||
nvr_t *nvr;
|
nvr_t *nvr;
|
||||||
|
char *fn;
|
||||||
ddma_t *ddma;
|
ddma_t *ddma;
|
||||||
acpi_t *acpi;
|
acpi_t *acpi;
|
||||||
void *smbus;
|
void *smbus;
|
||||||
@@ -1077,7 +1078,6 @@ sis_5513_11_pci_to_isa_reset(sis_5513_pci_to_isa_t *dev)
|
|||||||
dev->sis->ide_bits_1_3_writable = 0;
|
dev->sis->ide_bits_1_3_writable = 0;
|
||||||
dev->sis->usb_enabled = 0;
|
dev->sis->usb_enabled = 0;
|
||||||
|
|
||||||
sis_5513_apc_reset(dev);
|
|
||||||
sis_5513_apc_recalc(dev, 0);
|
sis_5513_apc_recalc(dev, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1132,7 +1132,6 @@ sis_5513_b0_pci_to_isa_reset(sis_5513_pci_to_isa_t *dev)
|
|||||||
|
|
||||||
dev->sis->usb_enabled = 0;
|
dev->sis->usb_enabled = 0;
|
||||||
|
|
||||||
sis_5513_apc_reset(dev);
|
|
||||||
sis_5513_apc_recalc(dev, 0);
|
sis_5513_apc_recalc(dev, 0);
|
||||||
|
|
||||||
if (dev->rev == 0x81)
|
if (dev->rev == 0x81)
|
||||||
@@ -1196,6 +1195,17 @@ static void
|
|||||||
sis_5513_pci_to_isa_close(void *priv)
|
sis_5513_pci_to_isa_close(void *priv)
|
||||||
{
|
{
|
||||||
sis_5513_pci_to_isa_t *dev = (sis_5513_pci_to_isa_t *) priv;
|
sis_5513_pci_to_isa_t *dev = (sis_5513_pci_to_isa_t *) priv;
|
||||||
|
FILE *fp = NULL;
|
||||||
|
|
||||||
|
fp = nvr_fopen(dev->fn, "wb");
|
||||||
|
|
||||||
|
if (fp != NULL) {
|
||||||
|
(void) fwrite(dev->apc_regs, 256, 1, fp);
|
||||||
|
fclose(fp);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (dev->fn != NULL)
|
||||||
|
free(dev->fn);
|
||||||
|
|
||||||
free(dev);
|
free(dev);
|
||||||
}
|
}
|
||||||
@@ -1205,6 +1215,8 @@ sis_5513_pci_to_isa_init(UNUSED(const device_t *info))
|
|||||||
{
|
{
|
||||||
sis_5513_pci_to_isa_t *dev = (sis_5513_pci_to_isa_t *) calloc(1, sizeof(sis_5513_pci_to_isa_t));
|
sis_5513_pci_to_isa_t *dev = (sis_5513_pci_to_isa_t *) calloc(1, sizeof(sis_5513_pci_to_isa_t));
|
||||||
uint8_t pit_is_fast = (((pit_mode == -1) && is486) || (pit_mode == 1));
|
uint8_t pit_is_fast = (((pit_mode == -1) && is486) || (pit_mode == 1));
|
||||||
|
FILE *fp = NULL;
|
||||||
|
int c;
|
||||||
|
|
||||||
dev->rev = info->local;
|
dev->rev = info->local;
|
||||||
|
|
||||||
@@ -1272,6 +1284,22 @@ sis_5513_pci_to_isa_init(UNUSED(const device_t *info))
|
|||||||
dev->sis->acpi->priv = dev->sis;
|
dev->sis->acpi->priv = dev->sis;
|
||||||
acpi_set_slot(dev->sis->acpi, dev->sis->sb_pci_slot);
|
acpi_set_slot(dev->sis->acpi, dev->sis->sb_pci_slot);
|
||||||
acpi_set_nvr(dev->sis->acpi, dev->nvr);
|
acpi_set_nvr(dev->sis->acpi, dev->nvr);
|
||||||
|
|
||||||
|
/* Set up the NVR file's name. */
|
||||||
|
c = strlen(machine_get_internal_name()) + 9;
|
||||||
|
dev->fn = (char *) malloc(c + 1);
|
||||||
|
sprintf(dev->fn, "%s_apc.nvr", machine_get_internal_name());
|
||||||
|
|
||||||
|
fp = nvr_fopen(dev->fn, "rb");
|
||||||
|
|
||||||
|
memset(dev->apc_regs, 0x00, sizeof(dev->apc_regs));
|
||||||
|
sis_5513_apc_reset(dev);
|
||||||
|
if (fp != NULL) {
|
||||||
|
if (fread(dev->apc_regs, 1, 256, fp) != 256)
|
||||||
|
fatal("sis_5513_pci_to_isa_init(): Error reading APC data\n");
|
||||||
|
fclose(fp);
|
||||||
|
}
|
||||||
|
|
||||||
acpi_set_irq_mode(dev->sis->acpi, 2);
|
acpi_set_irq_mode(dev->sis->acpi, 2);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -521,6 +521,7 @@ extern int machine_at_403tg_d_init(const machine_t *);
|
|||||||
extern int machine_at_403tg_d_mr_init(const machine_t *);
|
extern int machine_at_403tg_d_mr_init(const machine_t *);
|
||||||
extern int machine_at_pb450_init(const machine_t *);
|
extern int machine_at_pb450_init(const machine_t *);
|
||||||
extern int machine_at_pb450_init(const machine_t *);
|
extern int machine_at_pb450_init(const machine_t *);
|
||||||
|
extern int machine_at_aptiva_510_init(const machine_t *);
|
||||||
extern int machine_at_pc330_6573_init(const machine_t *);
|
extern int machine_at_pc330_6573_init(const machine_t *);
|
||||||
extern int machine_at_mvi486_init(const machine_t *);
|
extern int machine_at_mvi486_init(const machine_t *);
|
||||||
|
|
||||||
@@ -705,6 +706,7 @@ extern int machine_at_pb810_init(const machine_t *);
|
|||||||
extern int machine_at_mb520n_init(const machine_t *);
|
extern int machine_at_mb520n_init(const machine_t *);
|
||||||
extern int machine_at_i430vx_init(const machine_t *);
|
extern int machine_at_i430vx_init(const machine_t *);
|
||||||
|
|
||||||
|
extern int machine_at_ma23c_init(const machine_t *);
|
||||||
extern int machine_at_nupro592_init(const machine_t *);
|
extern int machine_at_nupro592_init(const machine_t *);
|
||||||
extern int machine_at_tx97_init(const machine_t *);
|
extern int machine_at_tx97_init(const machine_t *);
|
||||||
#if defined(DEV_BRANCH) && defined(USE_AN430TX)
|
#if defined(DEV_BRANCH) && defined(USE_AN430TX)
|
||||||
@@ -799,6 +801,7 @@ extern int machine_at_borapro_init(const machine_t *);
|
|||||||
extern int machine_at_ms6168_init(const machine_t *);
|
extern int machine_at_ms6168_init(const machine_t *);
|
||||||
|
|
||||||
extern int machine_at_p6f99_init(const machine_t *);
|
extern int machine_at_p6f99_init(const machine_t *);
|
||||||
|
extern int machine_at_m747_init(const machine_t *);
|
||||||
|
|
||||||
/* m_at_slot2.c */
|
/* m_at_slot2.c */
|
||||||
extern int machine_at_6gxu_init(const machine_t *);
|
extern int machine_at_6gxu_init(const machine_t *);
|
||||||
|
|||||||
@@ -550,6 +550,7 @@ extern const device_t ibm_ps1_2121_device;
|
|||||||
/* Trident TVGA 8900 */
|
/* Trident TVGA 8900 */
|
||||||
extern const device_t tvga8900b_device;
|
extern const device_t tvga8900b_device;
|
||||||
extern const device_t tvga8900d_device;
|
extern const device_t tvga8900d_device;
|
||||||
|
extern const device_t tvga8900dr_device;
|
||||||
extern const device_t tvga9000b_device;
|
extern const device_t tvga9000b_device;
|
||||||
extern const device_t nec_sv9000_device;
|
extern const device_t nec_sv9000_device;
|
||||||
|
|
||||||
|
|||||||
@@ -693,17 +693,9 @@ machine_at_pb450_init(const machine_t *model)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
static void
|
||||||
machine_at_pc330_6573_init(const machine_t *model) /* doesn't like every CPU other than the iDX4 and the Intel OverDrive, hangs without a PS/2 mouse */
|
machine_at_pc330_6573_common_init(const machine_t *model)
|
||||||
{
|
{
|
||||||
int ret;
|
|
||||||
|
|
||||||
ret = bios_load_linear("roms/machines/pc330_6573/$IMAGES.USF",
|
|
||||||
0x000e0000, 131072, 0);
|
|
||||||
|
|
||||||
if (bios_only || !ret)
|
|
||||||
return ret;
|
|
||||||
|
|
||||||
machine_at_common_init_ex(model, 2);
|
machine_at_common_init_ex(model, 2);
|
||||||
device_add(&ide_vlb_2ch_device);
|
device_add(&ide_vlb_2ch_device);
|
||||||
|
|
||||||
@@ -718,7 +710,7 @@ machine_at_pc330_6573_init(const machine_t *model) /* doesn't like every CPU oth
|
|||||||
pci_register_slot(0x0E, PCI_CARD_VIDEO, 13, 14, 15, 16);
|
pci_register_slot(0x0E, PCI_CARD_VIDEO, 13, 14, 15, 16);
|
||||||
|
|
||||||
if (gfxcard[0] == VID_INTERNAL)
|
if (gfxcard[0] == VID_INTERNAL)
|
||||||
device_add(&gd5430_onboard_vlb_device);
|
device_add(machine_get_vid_device(machine));
|
||||||
|
|
||||||
device_add(&opti602_device);
|
device_add(&opti602_device);
|
||||||
device_add(&opti802g_device);
|
device_add(&opti802g_device);
|
||||||
@@ -727,6 +719,36 @@ machine_at_pc330_6573_init(const machine_t *model) /* doesn't like every CPU oth
|
|||||||
device_add(&fdc37c665_ide_device);
|
device_add(&fdc37c665_ide_device);
|
||||||
device_add(&ide_opti611_vlb_device);
|
device_add(&ide_opti611_vlb_device);
|
||||||
device_add(&intel_flash_bxt_device);
|
device_add(&intel_flash_bxt_device);
|
||||||
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
machine_at_aptiva_510_init(const machine_t *model)
|
||||||
|
{
|
||||||
|
int ret;
|
||||||
|
|
||||||
|
ret = bios_load_linear("roms/machines/aptiva_510/$IMAGES.USF",
|
||||||
|
0x000e0000, 131072, 0);
|
||||||
|
|
||||||
|
if (bios_only || !ret)
|
||||||
|
return ret;
|
||||||
|
|
||||||
|
machine_at_pc330_6573_common_init(model);
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
machine_at_pc330_6573_init(const machine_t *model)
|
||||||
|
{
|
||||||
|
int ret;
|
||||||
|
|
||||||
|
ret = bios_load_linear("roms/machines/pc330_6573/$IMAGES.USF",
|
||||||
|
0x000e0000, 131072, 0);
|
||||||
|
|
||||||
|
if (bios_only || !ret)
|
||||||
|
return ret;
|
||||||
|
|
||||||
|
machine_at_pc330_6573_common_init(model);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -841,3 +841,30 @@ machine_at_p6f99_init(const machine_t *model)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
machine_at_m747_init(const machine_t *model)
|
||||||
|
{
|
||||||
|
int ret;
|
||||||
|
|
||||||
|
ret = bios_load_linear("roms/machines/m747/990521.rom",
|
||||||
|
0x000c0000, 262144, 0);
|
||||||
|
|
||||||
|
if (bios_only || !ret)
|
||||||
|
return ret;
|
||||||
|
|
||||||
|
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(0x01, PCI_CARD_SOUTHBRIDGE, 0, 0, 0, 0);
|
||||||
|
pci_register_slot(0x09, PCI_CARD_NORMAL, 1, 2, 3, 4);
|
||||||
|
pci_register_slot(0x0B, PCI_CARD_NORMAL, 4, 1, 2, 3);
|
||||||
|
pci_register_slot(0x0D, PCI_CARD_NORMAL, 3, 4, 1, 2);
|
||||||
|
pci_register_slot(0x02, PCI_CARD_AGPBRIDGE, 0, 0, 0, 0);
|
||||||
|
device_add(&sis_5600_device);
|
||||||
|
device_add(&keyboard_ps2_ami_pci_device);
|
||||||
|
device_add(&it8661f_device);
|
||||||
|
device_add(&winbond_flash_w29c020_device);
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|||||||
@@ -798,6 +798,37 @@ machine_at_i430vx_init(const machine_t *model)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
machine_at_ma23c_init(const machine_t *model)
|
||||||
|
{
|
||||||
|
int ret;
|
||||||
|
|
||||||
|
ret = bios_load_linear("roms/machines/ma23c/BIOS.ROM",
|
||||||
|
0x000c0000, 262144, 0);
|
||||||
|
|
||||||
|
if (bios_only || !ret)
|
||||||
|
return ret;
|
||||||
|
|
||||||
|
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(0x14, PCI_CARD_NORMAL, 1, 2, 3, 4);
|
||||||
|
pci_register_slot(0x12, PCI_CARD_NORMAL, 2, 3, 4, 1);
|
||||||
|
pci_register_slot(0x0C, PCI_CARD_NORMAL, 1, 2, 3, 4);
|
||||||
|
pci_register_slot(0x07, PCI_CARD_SOUTHBRIDGE, 1, 2, 3, 4);
|
||||||
|
pci_register_slot(0x0B, PCI_CARD_VIDEO, 3, 4, 1, 2);
|
||||||
|
device_add(&i430tx_device);
|
||||||
|
device_add(&piix4_device);
|
||||||
|
device_add(&nec_mate_unk_device);
|
||||||
|
device_add(&keyboard_ps2_ami_pci_device);
|
||||||
|
device_add(&fdc37c67x_device);
|
||||||
|
device_add(&intel_flash_bxt_device);
|
||||||
|
spd_register(SPD_TYPE_SDRAM, 0x7, 256);
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
machine_at_nupro592_init(const machine_t *model)
|
machine_at_nupro592_init(const machine_t *model)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -7185,6 +7185,46 @@ const machine_t machines[] = {
|
|||||||
.net_device = NULL
|
.net_device = NULL
|
||||||
},
|
},
|
||||||
/* Has IBM PS/2 Type 1 KBC firmware. */
|
/* Has IBM PS/2 Type 1 KBC firmware. */
|
||||||
|
{
|
||||||
|
.name = "[OPTi 802G] IBM Aptiva 510/710/Vision",
|
||||||
|
.internal_name = "aptiva_510",
|
||||||
|
.type = MACHINE_TYPE_486_S3,
|
||||||
|
.chipset = MACHINE_CHIPSET_OPTI_895_802G,
|
||||||
|
.init = machine_at_aptiva_510_init,
|
||||||
|
.p1_handler = NULL,
|
||||||
|
.gpio_handler = NULL,
|
||||||
|
.available_flag = MACHINE_AVAILABLE,
|
||||||
|
.gpio_acpi_handler = NULL,
|
||||||
|
.cpu = {
|
||||||
|
.package = CPU_PKG_SOCKET3_PC330,
|
||||||
|
.block = CPU_BLOCK_NONE,
|
||||||
|
.min_bus = 25000000,
|
||||||
|
.max_bus = 33333333,
|
||||||
|
.min_voltage = 0,
|
||||||
|
.max_voltage = 0,
|
||||||
|
.min_multi = 2.0,
|
||||||
|
.max_multi = 3.0
|
||||||
|
},
|
||||||
|
.bus_flags = MACHINE_PS2_PCI,
|
||||||
|
.flags = MACHINE_IDE | MACHINE_VIDEO | MACHINE_APM,
|
||||||
|
.ram = {
|
||||||
|
.min = 1024,
|
||||||
|
.max = 65536,
|
||||||
|
.step = 1024
|
||||||
|
},
|
||||||
|
.nvrmask = 255,
|
||||||
|
.kbc_device = NULL,
|
||||||
|
.kbc_p1 = 0xff,
|
||||||
|
.gpio = 0xffffffff,
|
||||||
|
.gpio_acpi = 0xffffffff,
|
||||||
|
.device = NULL,
|
||||||
|
.fdc_device = NULL,
|
||||||
|
.sio_device = NULL,
|
||||||
|
.vid_device = &gd5430_onboard_pci_device,
|
||||||
|
.snd_device = NULL,
|
||||||
|
.net_device = NULL
|
||||||
|
},
|
||||||
|
/* Has IBM PS/2 Type 1 KBC firmware. */
|
||||||
{
|
{
|
||||||
.name = "[OPTi 802G] IBM PC 330 (type 6573)",
|
.name = "[OPTi 802G] IBM PC 330 (type 6573)",
|
||||||
.internal_name = "pc330_6573",
|
.internal_name = "pc330_6573",
|
||||||
@@ -11957,6 +11997,47 @@ const machine_t machines[] = {
|
|||||||
.snd_device = NULL,
|
.snd_device = NULL,
|
||||||
.net_device = NULL
|
.net_device = NULL
|
||||||
},
|
},
|
||||||
|
/* Has a SM(S)C FDC37C67x Super I/O chip with on-chip KBC with Phoenix or
|
||||||
|
AMIKey-2 KBC firmware. */
|
||||||
|
{
|
||||||
|
.name = "[i430TX] NEC Mate NX MA23C",
|
||||||
|
.internal_name = "ma23c",
|
||||||
|
.type = MACHINE_TYPE_SOCKET7,
|
||||||
|
.chipset = MACHINE_CHIPSET_INTEL_430TX,
|
||||||
|
.init = machine_at_ma23c_init,
|
||||||
|
.p1_handler = NULL,
|
||||||
|
.gpio_handler = NULL,
|
||||||
|
.available_flag = MACHINE_AVAILABLE,
|
||||||
|
.gpio_acpi_handler = NULL,
|
||||||
|
.cpu = {
|
||||||
|
.package = CPU_PKG_SOCKET5_7,
|
||||||
|
.block = CPU_BLOCK_NONE,
|
||||||
|
.min_bus = 60000000,
|
||||||
|
.max_bus = 66666667,
|
||||||
|
.min_voltage = 2700,
|
||||||
|
.max_voltage = 3520,
|
||||||
|
.min_multi = 1.5,
|
||||||
|
.max_multi = 3.0
|
||||||
|
},
|
||||||
|
.bus_flags = MACHINE_PS2_PCI,
|
||||||
|
.flags = MACHINE_IDE_DUAL | MACHINE_APM | MACHINE_ACPI | MACHINE_USB,
|
||||||
|
.ram = {
|
||||||
|
.min = 8192,
|
||||||
|
.max = 786432,
|
||||||
|
.step = 8192
|
||||||
|
},
|
||||||
|
.nvrmask = 255,
|
||||||
|
.kbc_device = NULL,
|
||||||
|
.kbc_p1 = 0xff,
|
||||||
|
.gpio = 0xffffffff,
|
||||||
|
.gpio_acpi = 0xffffffff,
|
||||||
|
.device = NULL,
|
||||||
|
.fdc_device = NULL,
|
||||||
|
.sio_device = NULL,
|
||||||
|
.vid_device = NULL,
|
||||||
|
.snd_device = NULL,
|
||||||
|
.net_device = NULL
|
||||||
|
},
|
||||||
/* The BIOS sends KBC command BB and expects it to output a byte, which is AMI KBC behavior.
|
/* The BIOS sends KBC command BB and expects it to output a byte, which is AMI KBC behavior.
|
||||||
A picture shows a VIA VT82C42N KBC though, so it could be a case of that KBC with AMI firmware. */
|
A picture shows a VIA VT82C42N KBC though, so it could be a case of that KBC with AMI firmware. */
|
||||||
{
|
{
|
||||||
@@ -13643,7 +13724,7 @@ const machine_t machines[] = {
|
|||||||
.snd_device = NULL,
|
.snd_device = NULL,
|
||||||
.net_device = NULL
|
.net_device = NULL
|
||||||
},
|
},
|
||||||
/* Has a SM(S)C FDC37M60x Super I/O chip with on-chip KBC with Phoenix or
|
/* Has a SM(S)C FDC37C67x Super I/O chip with on-chip KBC with Phoenix or
|
||||||
AMIKey-2 KBC firmware. */
|
AMIKey-2 KBC firmware. */
|
||||||
{
|
{
|
||||||
.name = "[i440LX] NEC Mate NX MA30D/23D",
|
.name = "[i440LX] NEC Mate NX MA30D/23D",
|
||||||
@@ -14432,6 +14513,46 @@ const machine_t machines[] = {
|
|||||||
.snd_device = &es1371_onboard_device, /* ES1373 but we currently don't emulate that. */
|
.snd_device = &es1371_onboard_device, /* ES1373 but we currently don't emulate that. */
|
||||||
.net_device = NULL
|
.net_device = NULL
|
||||||
},
|
},
|
||||||
|
/* Has the SiS (5)600 chipset with on-chip KBC. */
|
||||||
|
{
|
||||||
|
.name = "[SiS 5600] PC Chips M747",
|
||||||
|
.internal_name = "m747",
|
||||||
|
.type = MACHINE_TYPE_SLOT1,
|
||||||
|
.chipset = MACHINE_CHIPSET_SIS_5600,
|
||||||
|
.init = machine_at_m747_init,
|
||||||
|
.p1_handler = NULL,
|
||||||
|
.gpio_handler = NULL,
|
||||||
|
.available_flag = MACHINE_AVAILABLE,
|
||||||
|
.gpio_acpi_handler = NULL,
|
||||||
|
.cpu = {
|
||||||
|
.package = CPU_PKG_SLOT1,
|
||||||
|
.block = CPU_BLOCK_NONE,
|
||||||
|
.min_bus = 66666667,
|
||||||
|
.max_bus = 100000000,
|
||||||
|
.min_voltage = 1300,
|
||||||
|
.max_voltage = 3500,
|
||||||
|
.min_multi = 1.5,
|
||||||
|
.max_multi = 8.0
|
||||||
|
},
|
||||||
|
.bus_flags = MACHINE_PS2_PCI,
|
||||||
|
.flags = MACHINE_IDE_DUAL | MACHINE_APM | MACHINE_ACPI | MACHINE_GAMEPORT | MACHINE_USB,
|
||||||
|
.ram = {
|
||||||
|
.min = 8192,
|
||||||
|
.max = 1572864,
|
||||||
|
.step = 1024
|
||||||
|
},
|
||||||
|
.nvrmask = 255,
|
||||||
|
.kbc_device = NULL,
|
||||||
|
.kbc_p1 = 0xff,
|
||||||
|
.gpio = 0xffffffff,
|
||||||
|
.gpio_acpi = 0xffffffff,
|
||||||
|
.device = NULL,
|
||||||
|
.fdc_device = NULL,
|
||||||
|
.sio_device = NULL,
|
||||||
|
.vid_device = NULL,
|
||||||
|
.snd_device = NULL,
|
||||||
|
.net_device = NULL
|
||||||
|
},
|
||||||
|
|
||||||
/* Slot 1/2 machines */
|
/* Slot 1/2 machines */
|
||||||
/* 440GX */
|
/* 440GX */
|
||||||
|
|||||||
@@ -63,7 +63,9 @@
|
|||||||
#define ET4000_TYPE_KASAN 5 /* Kasan ET4000 */
|
#define ET4000_TYPE_KASAN 5 /* Kasan ET4000 */
|
||||||
|
|
||||||
#define BIOS_ROM_PATH "roms/video/et4000/ET4000.BIN"
|
#define BIOS_ROM_PATH "roms/video/et4000/ET4000.BIN"
|
||||||
|
#define V8_06_BIOS_ROM_PATH "roms/video/et4000/ET4000_V8_06.BIN"
|
||||||
#define TC6058AF_BIOS_ROM_PATH "roms/video/et4000/Tseng_Labs_VGA-4000_BIOS_V1.1.bin"
|
#define TC6058AF_BIOS_ROM_PATH "roms/video/et4000/Tseng_Labs_VGA-4000_BIOS_V1.1.bin"
|
||||||
|
#define V1_21_BIOS_ROM_PATH "roms/video/et4000/Tseng_Labs_VGA-4000_BIOS_V1.21.bin"
|
||||||
#define KOREAN_BIOS_ROM_PATH "roms/video/et4000/tgkorvga.bin"
|
#define KOREAN_BIOS_ROM_PATH "roms/video/et4000/tgkorvga.bin"
|
||||||
#define KOREAN_FONT_ROM_PATH "roms/video/et4000/tg_ksc5601.rom"
|
#define KOREAN_FONT_ROM_PATH "roms/video/et4000/tg_ksc5601.rom"
|
||||||
#define KASAN_BIOS_ROM_PATH "roms/video/et4000/et4000_kasan16.bin"
|
#define KASAN_BIOS_ROM_PATH "roms/video/et4000/et4000_kasan16.bin"
|
||||||
@@ -783,6 +785,7 @@ et4000_mca_feedb(UNUSED(void *priv))
|
|||||||
static void *
|
static void *
|
||||||
et4000_init(const device_t *info)
|
et4000_init(const device_t *info)
|
||||||
{
|
{
|
||||||
|
const char *bios_ver = NULL;
|
||||||
const char *fn;
|
const char *fn;
|
||||||
et4000_t *dev;
|
et4000_t *dev;
|
||||||
int i;
|
int i;
|
||||||
@@ -803,8 +806,8 @@ et4000_init(const device_t *info)
|
|||||||
NULL, NULL);
|
NULL, NULL);
|
||||||
io_sethandler(0x03c0, 32,
|
io_sethandler(0x03c0, 32,
|
||||||
et4000_in, NULL, NULL, et4000_out, NULL, NULL, dev);
|
et4000_in, NULL, NULL, et4000_out, NULL, NULL, dev);
|
||||||
if (dev->type == ET4000_TYPE_TC6058AF)
|
bios_ver = (char *) device_get_config_bios("bios_ver");
|
||||||
fn = TC6058AF_BIOS_ROM_PATH;
|
fn = (char *) device_get_bios_file(info, bios_ver, 0);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ET4000_TYPE_MCA: /* MCA ET4000AX */
|
case ET4000_TYPE_MCA: /* MCA ET4000AX */
|
||||||
@@ -925,12 +928,6 @@ et4000_force_redraw(void *priv)
|
|||||||
dev->svga.fullchange = changeframecount;
|
dev->svga.fullchange = changeframecount;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
|
||||||
et4000_tc6058af_available(void)
|
|
||||||
{
|
|
||||||
return rom_present(TC6058AF_BIOS_ROM_PATH);
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
static int
|
||||||
et4000_available(void)
|
et4000_available(void)
|
||||||
{
|
{
|
||||||
@@ -970,12 +967,75 @@ static const device_config_t et4000_tc6058af_config[] = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
.name = "bios_ver",
|
||||||
|
.description = "BIOS Version",
|
||||||
|
.type = CONFIG_BIOS,
|
||||||
|
.default_string = "v1_10",
|
||||||
|
.default_int = 0,
|
||||||
|
.file_filter = "",
|
||||||
|
.spinner = { 0 }, /*W1*/
|
||||||
|
.bios = {
|
||||||
|
{ .name = "Version 1.10", .internal_name = "v1_10", .bios_type = BIOS_NORMAL,
|
||||||
|
.files_no = 1, .local = 0, .size = 32768, .files = { TC6058AF_BIOS_ROM_PATH, "" } },
|
||||||
|
{ .name = "Version 1.21", .internal_name = "v1_21", .bios_type = BIOS_NORMAL,
|
||||||
|
.files_no = 1, .local = 0, .size = 32768, .files = { V1_21_BIOS_ROM_PATH, "" } },
|
||||||
|
{ .files_no = 0 }
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
.type = CONFIG_END
|
.type = CONFIG_END
|
||||||
}
|
}
|
||||||
// clang-format on
|
// clang-format on
|
||||||
};
|
};
|
||||||
|
|
||||||
|
static const device_config_t et4000_bios_config[] = {
|
||||||
|
// clang-format off
|
||||||
|
{
|
||||||
|
.name = "memory",
|
||||||
|
.description = "Memory size",
|
||||||
|
.type = CONFIG_SELECTION,
|
||||||
|
.default_int = 1024,
|
||||||
|
.selection = {
|
||||||
|
{
|
||||||
|
.description = "256 KB",
|
||||||
|
.value = 256
|
||||||
|
},
|
||||||
|
{
|
||||||
|
.description = "512 KB",
|
||||||
|
.value = 512
|
||||||
|
},
|
||||||
|
{
|
||||||
|
.description = "1 MB",
|
||||||
|
.value = 1024
|
||||||
|
},
|
||||||
|
{
|
||||||
|
.description = ""
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
.name = "bios_ver",
|
||||||
|
.description = "BIOS Version",
|
||||||
|
.type = CONFIG_BIOS,
|
||||||
|
.default_string = "v8_01",
|
||||||
|
.default_int = 0,
|
||||||
|
.file_filter = "",
|
||||||
|
.spinner = { 0 }, /*W1*/
|
||||||
|
.bios = {
|
||||||
|
{ .name = "Version 8.01", .internal_name = "v8_01", .bios_type = BIOS_NORMAL,
|
||||||
|
.files_no = 1, .local = 0, .size = 32768, .files = { BIOS_ROM_PATH, "" } },
|
||||||
|
{ .name = "Version 8.06", .internal_name = "v8_06", .bios_type = BIOS_NORMAL,
|
||||||
|
.files_no = 1, .local = 0, .size = 32768, .files = { V8_06_BIOS_ROM_PATH, "" } },
|
||||||
|
{ .files_no = 0 }
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
.type = CONFIG_END
|
||||||
|
}
|
||||||
|
// clang-format on
|
||||||
|
};
|
||||||
|
|
||||||
static const device_config_t et4000_config[] = {
|
static const device_config_t et4000_config[] = {
|
||||||
// clang-format off
|
// clang-format off
|
||||||
{
|
{
|
||||||
@@ -1015,7 +1075,7 @@ const device_t et4000_tc6058af_isa_device = {
|
|||||||
.init = et4000_init,
|
.init = et4000_init,
|
||||||
.close = et4000_close,
|
.close = et4000_close,
|
||||||
.reset = NULL,
|
.reset = NULL,
|
||||||
{ .available = et4000_tc6058af_available },
|
{ .available = NULL },
|
||||||
.speed_changed = et4000_speed_changed,
|
.speed_changed = et4000_speed_changed,
|
||||||
.force_redraw = et4000_force_redraw,
|
.force_redraw = et4000_force_redraw,
|
||||||
.config = et4000_tc6058af_config
|
.config = et4000_tc6058af_config
|
||||||
@@ -1029,10 +1089,10 @@ const device_t et4000_isa_device = {
|
|||||||
.init = et4000_init,
|
.init = et4000_init,
|
||||||
.close = et4000_close,
|
.close = et4000_close,
|
||||||
.reset = NULL,
|
.reset = NULL,
|
||||||
{ .available = et4000_available },
|
{ .available = NULL },
|
||||||
.speed_changed = et4000_speed_changed,
|
.speed_changed = et4000_speed_changed,
|
||||||
.force_redraw = et4000_force_redraw,
|
.force_redraw = et4000_force_redraw,
|
||||||
.config = et4000_config
|
.config = et4000_bios_config
|
||||||
};
|
};
|
||||||
|
|
||||||
const device_t et4000_mca_device = {
|
const device_t et4000_mca_device = {
|
||||||
|
|||||||
@@ -144,6 +144,7 @@ video_cards[] = {
|
|||||||
{ &sigma_device },
|
{ &sigma_device },
|
||||||
{ &tvga8900b_device },
|
{ &tvga8900b_device },
|
||||||
{ &tvga8900d_device },
|
{ &tvga8900d_device },
|
||||||
|
{ &tvga8900dr_device },
|
||||||
{ &tvga9000b_device },
|
{ &tvga9000b_device },
|
||||||
{ &nec_sv9000_device },
|
{ &nec_sv9000_device },
|
||||||
{ &et4000k_isa_device },
|
{ &et4000k_isa_device },
|
||||||
|
|||||||
@@ -37,6 +37,7 @@
|
|||||||
|
|
||||||
#define ROM_TVGA_8900B "roms/video/tvga/tvga8900b.vbi"
|
#define ROM_TVGA_8900B "roms/video/tvga/tvga8900b.vbi"
|
||||||
#define ROM_TVGA_8900CLD "roms/video/tvga/trident.bin"
|
#define ROM_TVGA_8900CLD "roms/video/tvga/trident.bin"
|
||||||
|
#define ROM_TVGA_8900DR "roms/video/tvga/8900DR.VBI"
|
||||||
#define ROM_TVGA_9000B "roms/video/tvga/tvga9000b.bin"
|
#define ROM_TVGA_9000B "roms/video/tvga/tvga9000b.bin"
|
||||||
#define ROM_TVGA_9000B_NEC_SV9000 "roms/video/tvga/SV9000.VBI"
|
#define ROM_TVGA_9000B_NEC_SV9000 "roms/video/tvga/SV9000.VBI"
|
||||||
|
|
||||||
@@ -59,6 +60,7 @@ typedef struct tvga_t {
|
|||||||
} tvga_t;
|
} tvga_t;
|
||||||
|
|
||||||
video_timings_t timing_tvga8900 = { .type = VIDEO_ISA, .write_b = 3, .write_w = 3, .write_l = 6, .read_b = 8, .read_w = 8, .read_l = 12 };
|
video_timings_t timing_tvga8900 = { .type = VIDEO_ISA, .write_b = 3, .write_w = 3, .write_l = 6, .read_b = 8, .read_w = 8, .read_l = 12 };
|
||||||
|
video_timings_t timing_tvga8900dr = { .type = VIDEO_ISA, .write_b = 3, .write_w = 3, .write_l = 6, .read_b = 5, .read_w = 5, .read_l = 10 };
|
||||||
video_timings_t timing_tvga9000 = { .type = VIDEO_ISA, .write_b = 7, .write_w = 7, .write_l = 12, .read_b = 7, .read_w = 7, .read_l = 12 };
|
video_timings_t timing_tvga9000 = { .type = VIDEO_ISA, .write_b = 7, .write_w = 7, .write_l = 12, .read_b = 7, .read_w = 7, .read_l = 12 };
|
||||||
|
|
||||||
static uint8_t crtc_mask[0x40] = {
|
static uint8_t crtc_mask[0x40] = {
|
||||||
@@ -417,7 +419,10 @@ tvga_init(const device_t *info)
|
|||||||
video_inform(VIDEO_FLAG_TYPE_SPECIAL, &timing_tvga9000);
|
video_inform(VIDEO_FLAG_TYPE_SPECIAL, &timing_tvga9000);
|
||||||
tvga->vram_size = 512 << 10;
|
tvga->vram_size = 512 << 10;
|
||||||
} else {
|
} else {
|
||||||
video_inform(VIDEO_FLAG_TYPE_SPECIAL, &timing_tvga8900);
|
if (info->local & 0x0100)
|
||||||
|
video_inform(VIDEO_FLAG_TYPE_SPECIAL, &timing_tvga8900dr);
|
||||||
|
else
|
||||||
|
video_inform(VIDEO_FLAG_TYPE_SPECIAL, &timing_tvga8900);
|
||||||
tvga->vram_size = device_get_config_int("memory") << 10;
|
tvga->vram_size = device_get_config_int("memory") << 10;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -428,7 +433,10 @@ tvga_init(const device_t *info)
|
|||||||
bios_fn = ROM_TVGA_8900B;
|
bios_fn = ROM_TVGA_8900B;
|
||||||
break;
|
break;
|
||||||
case TVGA8900CLD_ID:
|
case TVGA8900CLD_ID:
|
||||||
bios_fn = ROM_TVGA_8900CLD;
|
if (info->local & 0x0100)
|
||||||
|
bios_fn = ROM_TVGA_8900DR;
|
||||||
|
else
|
||||||
|
bios_fn = ROM_TVGA_8900CLD;
|
||||||
break;
|
break;
|
||||||
case TVGA9000B_ID:
|
case TVGA9000B_ID:
|
||||||
bios_fn = (info->local & 0x100) ? ROM_TVGA_9000B_NEC_SV9000 : ROM_TVGA_9000B;
|
bios_fn = (info->local & 0x100) ? ROM_TVGA_9000B_NEC_SV9000 : ROM_TVGA_9000B;
|
||||||
@@ -466,6 +474,12 @@ tvga8900d_available(void)
|
|||||||
return rom_present(ROM_TVGA_8900CLD);
|
return rom_present(ROM_TVGA_8900CLD);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int
|
||||||
|
tvga8900dr_available(void)
|
||||||
|
{
|
||||||
|
return rom_present(ROM_TVGA_8900DR);
|
||||||
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
tvga9000b_available(void)
|
tvga9000b_available(void)
|
||||||
{
|
{
|
||||||
@@ -564,6 +578,20 @@ const device_t tvga8900d_device = {
|
|||||||
.config = tvga_config
|
.config = tvga_config
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const device_t tvga8900dr_device = {
|
||||||
|
.name = "Trident TVGA 8900D-R",
|
||||||
|
.internal_name = "tvga8900dr",
|
||||||
|
.flags = DEVICE_ISA,
|
||||||
|
.local = TVGA8900CLD_ID | 0x0100,
|
||||||
|
.init = tvga_init,
|
||||||
|
.close = tvga_close,
|
||||||
|
.reset = NULL,
|
||||||
|
{ .available = tvga8900dr_available },
|
||||||
|
.speed_changed = tvga_speed_changed,
|
||||||
|
.force_redraw = tvga_force_redraw,
|
||||||
|
.config = tvga_config
|
||||||
|
};
|
||||||
|
|
||||||
const device_t tvga9000b_device = {
|
const device_t tvga9000b_device = {
|
||||||
.name = "Trident TVGA 9000B",
|
.name = "Trident TVGA 9000B",
|
||||||
.internal_name = "tvga9000b",
|
.internal_name = "tvga9000b",
|
||||||
|
|||||||
Reference in New Issue
Block a user