This commit is contained in:
Markus Fröschle
2012-10-13 21:39:10 +00:00
parent 601fb73564
commit e4671bd6de
3 changed files with 31 additions and 31 deletions

View File

@@ -27,46 +27,46 @@ SECTIONS {
*/ */
/* Memory mapped registers */ /* Memory mapped registers */
___MBAR = ABSOLUTE(0xFF000000); __MBAR = ABSOLUTE(0xFF000000);
___MMUBAR = ABSOLUTE(0xFF040000); __MMUBAR = ABSOLUTE(0xFF040000);
/* /*
* 4KB on-chip Core SRAM0: -> exception table and exception stack * 4KB on-chip Core SRAM0: -> exception table and exception stack
*/ */
___RAMBAR0 = ABSOLUTE(0xFF100000); __RAMBAR0 = ABSOLUTE(0xFF100000);
___RAMBAR0_SIZE = ABSOLUTE(0x00001000); __RAMBAR0_SIZE = ABSOLUTE(0x00001000);
___SUP_SP = ___RAMBAR0 + ___RAMBAR0_SIZE - 4; __SUP_SP = ABSOLUTE(__RAMBAR0 + __RAMBAR0_SIZE - 4);
/* 4KB on-chip Core SRAM1: -> modified code */ /* 4KB on-chip Core SRAM1: -> modified code */
___RAMBAR1 = ABSOLUTE(0xFF101000); __RAMBAR1 = ABSOLUTE(0xFF101000);
___RAMBAR1_SIZE = ABSOLUTE(0x00001000); __RAMBAR1_SIZE = ABSOLUTE(0x00001000);
/* Systemveriablem:****************************************** */ /* Systemveriablem:****************************************** */
/* RAMBAR0 0 bis 0x7FF -> exception vectoren */ /* RAMBAR0 0 bis 0x7FF -> exception vectoren */
_rt_mod = ___RAMBAR0 + 0x800; _rt_mod = __RAMBAR0 + 0x800;
_rt_ssp = ___RAMBAR0 + 0x804; _rt_ssp = __RAMBAR0 + 0x804;
_rt_usp = ___RAMBAR0 + 0x808; _rt_usp = __RAMBAR0 + 0x808;
_rt_vbr = ___RAMBAR0 + 0x80C; /* (8)01 */ _rt_vbr = __RAMBAR0 + 0x80C; /* (8)01 */
_rt_cacr = ___RAMBAR0 + 0x810; /* 002 */ _rt_cacr = __RAMBAR0 + 0x810; /* 002 */
_rt_asid = ___RAMBAR0 + 0x814; /* 003 */ _rt_asid = __RAMBAR0 + 0x814; /* 003 */
_rt_acr0 = ___RAMBAR0 + 0x818; /* 004 */ _rt_acr0 = __RAMBAR0 + 0x818; /* 004 */
_rt_acr1 = ___RAMBAR0 + 0x81c; /* 005 */ _rt_acr1 = __RAMBAR0 + 0x81c; /* 005 */
_rt_acr2 = ___RAMBAR0 + 0x820; /* 006 */ _rt_acr2 = __RAMBAR0 + 0x820; /* 006 */
_rt_acr3 = ___RAMBAR0 + 0x824; /* 007 */ _rt_acr3 = __RAMBAR0 + 0x824; /* 007 */
_rt_mmubar = ___RAMBAR0 + 0x828; /* 008 */ _rt_mmubar = __RAMBAR0 + 0x828; /* 008 */
_rt_sr = ___RAMBAR0 + 0x82c; _rt_sr = __RAMBAR0 + 0x82c;
_d0_save = ___RAMBAR0 + 0x830; _d0_save = __RAMBAR0 + 0x830;
_a7_save = ___RAMBAR0 + 0x834; _a7_save = __RAMBAR0 + 0x834;
_video_tlb = ___RAMBAR0 + 0x838; _video_tlb = __RAMBAR0 + 0x838;
_video_sbt = ___RAMBAR0 + 0x83C; _video_sbt = __RAMBAR0 + 0x83C;
_rt_mbar = ___RAMBAR0 + 0x844; /* (c)0f */ _rt_mbar = __RAMBAR0 + 0x844; /* (c)0f */
/**********************************************************/ /**********************************************************/
/* 32KB on-chip System SRAM */ /* 32KB on-chip System SRAM */
__SYS_SRAM = 0xFF010000; __SYS_SRAM = ABSOLUTE(0xFF010000);
__SYS_SRAM_SIZE = 0x00008000; __SYS_SRAM_SIZE = ABSOLUTE(0x00008000);
.code : {} > code .code : {} > code

View File

@@ -208,7 +208,7 @@ _vec_init:
clr.l _rt_ssp clr.l _rt_ssp
clr.l _rt_usp clr.l _rt_usp
clr.l _rt_vbr clr.l _rt_vbr
move.l #___RAMBAR0,d0 // sind in rambar0 move.l #__RAMBAR0,d0 // sind in rambar0
movec d0,VBR movec d0,VBR
move.l d0,a0 move.l d0,a0
move.l a0,a2 move.l a0,a2
@@ -220,7 +220,7 @@ init_vec_loop:
subq.l #1,d0 subq.l #1,d0
bne init_vec_loop bne init_vec_loop
move.l #___SUP_SP,(a0) move.l #__SUP_SP,(a0)
lea reset_vector(pc),a1 lea reset_vector(pc),a1
move.l a1,0x04(a0) move.l a1,0x04(a0)
lea acess(pc),a1 lea acess(pc),a1
@@ -366,7 +366,7 @@ reset_vector:
move.l #0x31415926,d0 move.l #0x31415926,d0
cmp.l 0x426,d0 // reset vector g<EFBFBD>ltg? cmp.l 0x426,d0 // reset vector g<EFBFBD>ltg?
beq std_exc_vec // ja-> beq std_exc_vec // ja->
jmp ___BOOT_FLASH // sonst kaltstart jmp __BOOT_FLASH // sonst kaltstart
acess: acess:
move.w #0x2700,sr // disable interrupt move.w #0x2700,sr // disable interrupt
move.l d0,-(sp) // ++ vr move.l d0,-(sp) // ++ vr
@@ -679,7 +679,7 @@ irq7:
lea -12(sp),sp lea -12(sp),sp
movem.l d0/a0,(sp) movem.l d0/a0,(sp)
move.l ___RAMBAR0+0x008,a0 // Real Access Error handler move.l __RAMBAR0+0x008,a0 // Real Access Error handler
move.l a0,8(sp) // This will be the return address for rts move.l a0,8(sp) // This will be the return address for rts
move.w 12(sp),d0 // Format/Vector word move.w 12(sp),d0 // Format/Vector word

View File

@@ -768,7 +768,7 @@ void __initialize_hardware(void) {
_init_hardware: _init_hardware:
asm( asm(
"move.l #0x000C8120,D0\n\t" "move.l #0x000C8120,D0\n\t"
"move.l D0,rt_cacr\n\t" "move.l D0,_rt_cacr\n\t"
"movec D0,CACR\n\t" "movec D0,CACR\n\t"
"nop\n\t" "nop\n\t"
); );