Dear FAE,
I Want to set up MMU of mpc5644a, the complier is WR Diab v5.9.3, after startup code(crt0.s), i try to initial the TLBs
as below, but it run with error to exception after first call CalcTLBEntry, the protype of function is as attached.
my question :
(1) what i need to do before initial MMU in crt0.s?
(2) about the problem , is any suggestion?
thanks for your reply!
void main(void)
{
CalcTLBEntry (TLBNr0, TLBValid, PorcessID0, TS0, Size64KByte , 0x00000000, 0x00000000, 0);//first 64kb
CalcTLBEntry (TLBNr1, TLBValid, PorcessID0, TS0, Size64KByte , 0x00010000, 0x00010000, 0);
CalcTLBEntry (TLBNr2, TLBValid, PorcessID0, TS0, Size64KByte , 0x00020000, 0x00020000, 0);
CalcTLBEntry (TLBNr3, TLBValid, PorcessID0, TS0, Size64KByte , 0x00030000, 0x00030000, 1);//for Cal_RP
CalcTLBEntry (TLBNr4, TLBValid, PorcessID0, TS0, Size256KByte , 0x00040000, 0x00040000, 1);//
CalcTLBEntry (TLBNr5, TLBValid, PorcessID0, TS0, Size256KByte , 0x00080000, 0x00080000, 1);//
CalcTLBEntry (TLBNr6, TLBValid, PorcessID0, TS0, Size256KByte , 0x000C0000, 0x000C0000, 1);//
CalcTLBEntry (TLBNr7, TLBValid, PorcessID0, TS0, Size1MByte , 0x00100000, 0x00100000, 1);//
CalcTLBEntry (TLBNr8, TLBValid, PorcessID0, TS0, Size256KByte , 0x40000000, 0x40000000, 1);//???? not sure