Re: [hatari-devel] TT emulation crashes when there is no ACSI drive |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/hatari-devel Archives
]
- To: hatari-devel@xxxxxxxxxxxxxxxxxxx
- Subject: Re: [hatari-devel] TT emulation crashes when there is no ACSI drive
- From: Uwe Seimet <Uwe.Seimet@xxxxxxxxx>
- Date: Sun, 11 Aug 2019 10:33:49 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1565512430; s=strato-dkim-0002; d=seimet.de; h=In-Reply-To:References:Message-ID:Subject:To:From:Date: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=yzdZWPx39ure13SFsofDIQxZhgfK1ywpmA4hgOCi7yY=; b=F9h3hSMaOlInHHVYeJydt/VLSMey6xHqIBpVmj460vOgo5jzDYFMfuGVJBu/Kjj6ZC CeuMiU8UHTjA/k8oXl2JI8W27EzRL+uwPLUG5xcvYgOWJxlgERU/+Fd7uFYTOnWlsZIc EHmzghK1bOMtJS7wB9GBZwWm/rnZw4Z/NnOamhHE1kSQP4OkAh2Aq7A4VJ1BEyNz4Kzo s94Mkszlz7DJBph6zK13t6oyvETUj+E8FwHNWVHNpcZzmGr/76Yr3+d8qSQ/agwL9iYO Kph1E9qGuwHEneJrx0bBTNIV734UJOYaUxuQOZyV5GOBAi+2zjhW/LWifgH2ZCGedPPC 9urw==
Hi,
I'm afraid this patch did not help. There was no visible change.
WARN : Bus Error writing at address $23000002, PC=$fa005c addr_e3=fa005c op_e3=42ae
Best regards
Uwe
> Le 11/08/2019 à 08:02, Uwe Seimet a écrit :
> > Hi,
> >
> > Disabling IDE disks does not make a difference.
> >
> > This is the offending commit:
> >
> > * 50bf142e - Merge new TT MFP code (3 months ago) <Nicolas Pomarede>
> >
> > Commit ID 65dda3cf and older work fine for me, since 50bf142e there is
> > the crash. My compiler is gcc 8.3.0, by the way.
> >
> > Best regards
> >
> > Uwe
> >
>
> Hi
>
> looking at the code, unlike what the commit's name imply, this is mostly
> about natfeat (which was merged with new MFP code).
>
> I don't know this part, but this looks suspicious to me :
>
> static int mem_string_ok(Uint32 addr)
> {
> ...
> for (i = 0; i < NF_MAX_STRING; i++) {
> if (!STMemory_CheckAreaType(addr, 1, ABFLAG_RAM |
> ABFLAG_ROM)) {
> /* ends in invalid area -> error */
> M68000_BusError(addr, BUS_ERROR_READ,
> BUS_ERROR_SIZE_BYTE, BUS_ERROR_ACCESS_DATA);
> return 0;
> }
> if (!buf[i]) {
> return i;
> }
> }
> }
>
> addr should be addr+i in these tests, else this always test the 1st byte
> which is pointless.
>
>
> could you try the following changes in src/debug/natfeats.c :
>
> --- natfeats.c 2019-05-28 21:49:21.701525671 +0200
> +++ natfeats.c 2019-08-11 10:20:09.387348678 +0200
> @@ -69,9 +69,9 @@ static int mem_string_ok(Uint32 addr)
> return 0;
> }
> for (i = 0; i < NF_MAX_STRING; i++) {
> - if (!STMemory_CheckAreaType(addr, 1, ABFLAG_RAM |
> ABFLAG_ROM)) {
> + if (!STMemory_CheckAreaType(addr+i, 1, ABFLAG_RAM |
> ABFLAG_ROM)) {
> /* ends in invalid area -> error */
> - M68000_BusError(addr, BUS_ERROR_READ,
> BUS_ERROR_SIZE_BYTE, BUS_ERROR_ACCESS_DATA);
> + M68000_BusError(addr+i, BUS_ERROR_READ,
> BUS_ERROR_SIZE_BYTE, BUS_ERROR_ACCESS_DATA);
> return 0;
> }
>
>
> Nicolas
>
>