More AT NVR and VIA fixes - the Gigabyte GA-6VX-4X AMI BIOS (machine will be added on the WIP branch) works fine now.
This commit is contained in:
15
src/acpi.c
15
src/acpi.c
@@ -480,7 +480,7 @@ acpi_reg_read_via(int size, uint16_t addr, void *p)
|
||||
case 0x42:
|
||||
/* GPIO port Output Value */
|
||||
if (size == 1)
|
||||
ret = (dev->regs.gpio_val & 0x2f) | 0x10;
|
||||
ret = dev->regs.gpio_val & 0x13;
|
||||
break;
|
||||
case 0x44:
|
||||
/* GPIO port Input Value */
|
||||
@@ -532,7 +532,7 @@ acpi_reg_read_via_596b(int size, uint16_t addr, void *p)
|
||||
case 0x42:
|
||||
/* GPIO port Output Value */
|
||||
if (size == 1)
|
||||
ret = (dev->regs.gpio_val & 0x2f) | 0x10;
|
||||
ret = dev->regs.gpio_val & 0x13;
|
||||
break;
|
||||
case 0x44: case 0x45:
|
||||
/* External SMI Input Value */
|
||||
@@ -1037,7 +1037,7 @@ acpi_reg_write_via(int size, uint16_t addr, uint8_t val, void *p)
|
||||
case 0x42:
|
||||
/* GPIO port Output Value */
|
||||
if (size == 1) {
|
||||
dev->regs.gpio_val = val & 0x2f;
|
||||
dev->regs.gpio_val = val & 0x13;
|
||||
acpi_i2c_set(dev);
|
||||
}
|
||||
break;
|
||||
@@ -1065,13 +1065,12 @@ acpi_reg_write_via_596b(int size, uint16_t addr, uint8_t val, void *p)
|
||||
switch (addr) {
|
||||
case 0x42:
|
||||
/* GPIO port Output Value */
|
||||
if (size == 1) {
|
||||
dev->regs.gpio_val = val & 0x2f;
|
||||
acpi_i2c_set(dev);
|
||||
}
|
||||
if (size == 1)
|
||||
dev->regs.gpio_val = val & 0x13;
|
||||
break;
|
||||
case 0x4c: case 0x4d: case 0x4e: case 0x4f:
|
||||
/* GPO Port Output Value */
|
||||
pclog("Write %02X to %02X\n", val, addr);
|
||||
dev->regs.gpo_val = ((dev->regs.gpo_val & ~(0xff << shift32)) | (val << shift32)) & 0x7fffffff;
|
||||
break;
|
||||
default:
|
||||
@@ -1583,7 +1582,7 @@ acpi_reset(void *priv)
|
||||
dev->regs.gpi_val |= 0x00000004;
|
||||
if (!strcmp(machines[machine].internal_name, "6via90ap"))
|
||||
dev->regs.gpi_val |= 0x00000004;
|
||||
dev->regs.gpi_val = 0xffffffe5;
|
||||
// dev->regs.gpi_val = 0xffffffe5;
|
||||
// dev->regs.gpi_val = 0x00000004;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user