From caef53a4a1687cf880d1dc82a4af38b734fc6e84 Mon Sep 17 00:00:00 2001 From: Volker Ruppert Date: Sun, 28 Jan 2024 11:05:16 +0100 Subject: [PATCH] Voodoo 1/2: Added support for dword aligned byte writes. TODO: For unaligned writes the voodoo_w() function needs to be modified. --- bochs/iodev/display/voodoo.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bochs/iodev/display/voodoo.cc b/bochs/iodev/display/voodoo.cc index e0d0f1880..2bf947759 100644 --- a/bochs/iodev/display/voodoo.cc +++ b/bochs/iodev/display/voodoo.cc @@ -1064,6 +1064,8 @@ void bx_voodoo_1_2_c::mem_write(bx_phy_address addr, unsigned len, void *data) } else { voodoo_w((addr >> 2) & 0x3FFFFF, (Bit32u)value, 0x0000ffff); } + } else if ((len == 1) && ((addr & 3) == 0)) { + voodoo_w((addr >> 2) & 0x3FFFFF, (Bit32u)value, 0x0000ffff); } else { BX_ERROR(("Voodoo mem_write(): unknown len=%d", len)); }