Fixed correct inline assembly usage.

This commit is contained in:
Vincent Rivière
2012-10-14 20:54:20 +00:00
parent dfd46f42c5
commit 707ccf004c

View File

@@ -2,7 +2,7 @@
void startup(void)
{
asm("\n\t"
__asm__ __volatile__ ("\n\t"
".extern _initialize_hardware\n\t"
"bra.s warmstart\n\t"
"jmp ___BOOT_FLASH + 8 | ist zugleich reset vector\n\t"
@@ -10,20 +10,20 @@ void startup(void)
"warmstart:\n\t"
"| disable interrupts\n\t"
"move.w #0x2700,sr\n\t"
);
: : : "memory");
/* Initialize MBAR */
asm("MOVE.L #__MBAR,D0\n\t");
asm("MOVEC D0,MBAR\n\t");
asm("MOVE.L D0,_rt_mbar\n\t");
__asm__ __volatile__ ("MOVE.L #__MBAR,D0\n\t" : : : "memory");
__asm__ __volatile__ ("MOVEC D0,MBAR\n\t" : : : "memory");
__asm__ __volatile__ ("MOVE.L D0,_rt_mbar\n\t" : : : "memory");
/* mmu off */
asm("move.l #__MMUBAR+1,d0\n\t");
asm("movec d0,MMUBAR"); /* set mmubar */
__asm__ __volatile__ ("move.l #__MMUBAR+1,d0\n\t" : : : "memory");
__asm__ __volatile__ ("movec d0,MMUBAR" : : : "memory"); /* set mmubar */
MCF_MMU_MMUCR = 0L; /* MMU off */
asm(
__asm__ __volatile__ (
"|/* Initialize RAMBARs: locate SRAM and validate it */\n\t"
"move.l #__RAMBAR0 + 0x7,d0\n\t | supervisor only"
"movec d0,RAMBAR0\n\t"
@@ -37,5 +37,5 @@ void startup(void)
"nop\n\t"
"| initialize any hardware specific issues\n\t"
"bra _initialize_hardware\n\t"
);
: : : "memory");
}