# HG changeset patch # User Michael Pavone # Date 1644708065 28800 # Node ID 68d61ba1b762ee10219c8f928b908410eeacfced # Parent f80c6111e1ae51f01f4cae8da4e001f391e9def8 Fix handling of byte writes to gate array regs from main CPU diff -r f80c6111e1ae -r 68d61ba1b762 segacd.c --- a/segacd.c Sat Feb 12 15:20:43 2022 -0800 +++ b/segacd.c Sat Feb 12 15:21:05 2022 -0800 @@ -1155,7 +1155,7 @@ segacd_context *cd = gen->expansion; uint32_t reg = (address & 0x1FF) >> 1; uint16_t value16; - switch (reg >> 1) + switch (reg) { case GA_SUB_CPU_CTRL: if (address & 1) {