[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] Trans.: Re: Questions about 68040



Hi,


Selon Konrad Kokoszkiewicz <draco@obta.uw.edu.pl>:
> > This is a well known problem on Falcon/CT2 where user could
> > access low mem in user mode.
> Eh, what? So this must be protected by MMU in MiNT then.

Didier Mequignon already worked on this.

Basically CT2 boot code (We're talking about CT2 here - CT60 is far better on 
this topic) always use the PMMU to remap its TT-RAM from $0x04000000 to the 
well known 0x01000000.

Didier wrote a small AUTO folder program which adds a supervisor protection on 
low mem. It's available on his web site 
(http://perso.wanadoo.fr/didierm , "download" page). This was later included 
into the CT2 boot code.

Since the PMMU is used, MiNT was unable to run with memory protection. So 
Didier wrote a specific patch to allow MP with MiNT on CT2. It's commited to 
CVS in sys/arch/mprot030.c (search for "CT2" there). This code handle the 
strange TT-RAM base address, but it seems nothing was done to add supervisor 
protection of low mem.

Anyway, it's not that easy. Reading the top of sys/arch/mprot030.c show us that 
MiNT uses 8K pages on 68 030. This means we can only protect 0x0000-0x1FFF at 
once. This is too much, since only 0x0000-0x07FF needs to be supervisor 
protected... We could find a way to do it nevertheless, but I don't think CT2 
deserve so much efforts.


Regards,


Xavier