Fix the initialization and general purpose I/O (GPIO) pins for the OptiPlex GXL/GXM

This commit is contained in:
rushieda
2025-05-19 20:59:08 +03:00
parent d7282ddc46
commit 9f46d0b9d8
2 changed files with 13 additions and 3 deletions

View File

@@ -1096,7 +1096,16 @@ write64_generic(void *priv, uint8_t val)
- Bit 5: Manufacturing jumper (must be set);
*/
uint8_t p1 = 0x24;
kbc_delay_to_ob(dev, p1, 0, 0x01);
kbc_delay_to_ob(dev, p1, 0, 0x00);
} else if (!strcmp(machine_get_internal_name(), "optiplex_gxl")) {
/*
Dell OptiPlex GXL/GXM:
- Bit 3: Password disable jumper (must be clear);
- Bit 4: Keyboard fuse (must be set);
- Bit 5: Manufacturing jumper (must be set);
*/
uint8_t p1 = 0x30;
kbc_delay_to_ob(dev, p1, 0, 0x00);
} else {
/* (B0 or F0) | (0x08 or 0x0c) */
uint8_t p1_out = ((dev->p1 | fixed_bits) & 0xf0) |