--- nono/vm/crtc2.cpp 2026/04/29 17:05:17 1.1.1.10 +++ nono/vm/crtc2.cpp 2026/04/29 17:05:24 1.1.1.11 @@ -57,7 +57,7 @@ CRTC2Device::ResetHard(bool poweron) scheduler->RestartEvent(vdisp_event); } -uint64 +busdata CRTC2Device::Read(uint32 offset) { uint32 data; @@ -97,17 +97,20 @@ CRTC2Device::Read(uint32 offset) default: VMPANIC("corrupted offset=%d", offset); } - return data; + + busdata bd = data; + // XXX wait? + return bd; } -uint64 +busdata CRTC2Device::Write(uint32 offset, uint32 data) { switch (offset) { case 0: // アドレスレジスタ ar = data & 0x3f; putlog(3, "Address Register <- $%02x", ar); - return 0; + break; case 1: // データレジスタ switch (ar) { @@ -125,14 +128,18 @@ CRTC2Device::Write(uint32 offset, uint32 putlog(2, "R%02d <- $%02x", ar, data); break; } - return 0; + break; default: VMPANIC("corrupted offset=%d", offset); + break; } + + // XXX wait? + return 0; } -uint64 +busdata CRTC2Device::Peek(uint32 offset) { switch (offset) {