- fixed bootloader makefile

- interupts disabled after bootloader
- enable interrupts in board file


git-svn-id: http://moon:8086/svn/mips@109 a8ebac50-d88d-4704-bea3-6648445a41b3
This commit is contained in:
2017-01-20 18:39:10 +00:00
parent 5261f6a93a
commit 6b228be3f7
6 changed files with 10 additions and 29 deletions
+5 -9
View File
@@ -152,7 +152,7 @@ void Exec_at(void *pEntry)
(
// Enable User Mode and Interrupts on RFE
// Exception Vector = 0xBFC00080
"li $26, 0x1000000C\n"
"li $26, 0x10000008\n"
"mtc0 $26, $12\n"
);
@@ -178,13 +178,6 @@ void PrintCPUinfo(void)
char *cpu_type_str[7] = {"invalid", "R2000", "R3000", "R6000", "R4000", "reserved", "R6000A"};
// Print Status register
result = CP0_SR_read();
sputs("Status : ");
print_word(result);
sputs("\n");
// Print Revision
result = CP0_PRID_read();
rev_id = (result >> 8) & 0xFF;
@@ -201,6 +194,8 @@ void PrintCPUinfo(void)
sputs("\n");
// Print Status register
sputs("Status : ");print_word(CP0_SR_read());sputs("\n");
}
#define MAX_IMG_SIZE (1024*1024) // bytes
@@ -220,7 +215,8 @@ int main(int argc, char *argv[])
volatile uint32_t *pSdram32 = (uint32_t*)SDRAM_BASE;
sputs("\nMIPS bootloader\n");
PrintCPUinfo();
// ----------------------------------------------------------
sputs("Loading image from flash at ");print_word((int)pFlashMem);sputs("\n");
img_hdr = *((flash_img_hdr_t*)pFlashMem);