Re: [hatari-devel] Hatari/TT VME adress space behavior |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/hatari-devel Archives
]
- To: hatari-devel@xxxxxxxxxxxxxxxxxxx, Uwe Seimet <Uwe.Seimet@xxxxxxxxx>
- Subject: Re: [hatari-devel] Hatari/TT VME adress space behavior
- From: Nicolas Pomarède <npomarede@xxxxxxxxxxxx>
- Date: Sat, 19 Jul 2025 12:07:19 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/simple; d=corp.free.fr; s=rcs; t=1752919640; bh=Aa1DyEdMEHl8ia9WKF0fM7LeJEedlcJFpfw1rvIZEGo=; h=Date:Subject:From:To:Reply-To:References:In-Reply-To:From; b=b+fDlr13XVNWn2gd+XAmhfnshFjT6QGoNE6F0kq2Q7U7SEc/2hLSfAJL8+To3GG0g WCJ4Sz73bsgKIovfbt7eOKM4XodMgP7aAT5z81xZLkQnDoA8R8jsF9p6teLEjmwS/z 1djRRvTwwRrPU47K8ax9UGjaUH4eM0QS1rJreBo1Bqxria4X1ijF3+OtMVDh2+Cv/2 nuozrPrCziKU9r90rV16tm2c507+ZdBWTcI0vAuuYyd6ex1phOuTFSXt3lHYHniFSM QXeX+qus4C5Amg9QsAU4I/vl5gVSKE/vXFvCnJqts/RKXMJ1D5mjIyfIx385thsNJx sznXG/bfc8Zdw==
Le 08/07/2025 à 10:14, Nicolas Pomarède a écrit :
Le 08/07/2025 à 10:12, Uwe Seimet a écrit :
Hi,
although some changes for SCU support can be seen as related to the VME
bus and its registers, Hatari does in fact very little regarding VME
itself, so it's quite possible it doesn't behave similarly to a real TT
as you describe.
But using reports as yours comparing real TT to emulation, it should be
possible to improve this, especially returning bus error should not be
too difficult (as Hatari doesn't support VME card emulation)
Any chance to get this implemented/fixed? After looking at the sources I
do not know how to do this, but maybe for somebody who has more
insight it
is just a minor effort?
Hi
it seems I lost track of this mail after the discussion went on DKIM /
mails problem.
I will add this to my todo list
Hi
can you try the attached patch on top of the current git devel version
of hatari ?
it should return bus error when accessing $FExxxxxx regions in MegaSTE
and TT mode.
Nicolas
diff --git a/src/cpu/memory.c b/src/cpu/memory.c
index c60d8bdb..2cbd8590 100644
--- a/src/cpu/memory.c
+++ b/src/cpu/memory.c
@@ -47,6 +47,8 @@ static uae_u32 TTmem_mask;
#define IOmem_start 0x00FF0000
#define TTmem_start 0x01000000 /* TOS 3 and TOS 4 always expect extra RAM at this address */
#define TTmem_end 0x80000000 /* Max value for end of TT ram, which gives 2047 MB */
+#define VMEmem_start 0xFE000000 /* MegaSTE and TT support a VME bus. This returns a bus error */
+#define VMEmem_end 0xFF000000 /* when no board is plugged */
#define IdeMem_size 65536
#define IOmem_size 65536
@@ -1813,6 +1815,13 @@ void memory_init(uae_u32 NewSTMemSize, uae_u32 NewTTMemSize, uae_u32 NewRomMemSt
map_banks_ce(&BusErrMem_bank, IdeMem_start >> 16, 0x1, 0, CE_MEMBANK_CHIP16, CE_MEMBANK_NOT_CACHABLE);
}
+ /* VME region on MegaSTE and TT : 0xFE000000 - 0xFEFFFFFF */
+ /* Hatari doesn't emulate VME board for now, so this region should return bus errors */
+ if ( Config_IsMachineMegaSTE() || Config_IsMachineTT() )
+ {
+ map_banks_ce(&BusErrMem_bank, VMEmem_start >> 16, ( VMEmem_end - VMEmem_start ) >> 16 , 0, CE_MEMBANK_CHIP16, CE_MEMBANK_NOT_CACHABLE);
+ }
+
/* Illegal memory regions cause a bus error on the ST: */
map_banks_ce(&BusErrMem_bank, 0xF10000 >> 16, 0x9, 0, CE_MEMBANK_CHIP16, CE_MEMBANK_NOT_CACHABLE);