[update][board] move kmem_init before print

This commit is contained in:
jzlv 2023-03-09 17:42:00 +08:00
parent 8a21081fd5
commit 942bcec6fe
3 changed files with 18 additions and 18 deletions

View file

@ -215,12 +215,6 @@ void board_init(void)
bflb_irq_initialize();
console_init();
bl_show_log();
if (ret != 0) {
printf("flash init fail!!!\r\n");
}
bl_show_flashinfo();
#ifdef CONFIG_PSRAM
board_psram_x8_init();
@ -230,6 +224,12 @@ void board_init(void)
size_t heap_len = ((size_t)&__HeapLimit - (size_t)&__HeapBase);
kmem_init((void *)&__HeapBase, heap_len);
bl_show_log();
if (ret != 0) {
printf("flash init fail!!!\r\n");
}
bl_show_flashinfo();
printf("dynamic memory init success,heap size = %d Kbyte \r\n", ((size_t)&__HeapLimit - (size_t)&__HeapBase) / 1024);
printf("sig1:%08x\r\n", BL_RD_REG(GLB_BASE, GLB_UART_CFG1));

View file

@ -236,12 +236,6 @@ void board_init(void)
console_init();
bl_show_log();
if (ret != 0) {
printf("flash init fail!!!\r\n");
}
bl_show_flashinfo();
#ifdef CONFIG_PSRAM
board_psram_init();
#endif
@ -249,6 +243,12 @@ void board_init(void)
size_t heap_len = ((size_t)&__HeapLimit - (size_t)&__HeapBase);
kmem_init((void *)&__HeapBase, heap_len);
bl_show_log();
if (ret != 0) {
printf("flash init fail!!!\r\n");
}
bl_show_flashinfo();
printf("dynamic memory init success,heap size = %d Kbyte \r\n", ((size_t)&__HeapLimit - (size_t)&__HeapBase) / 1024);
printf("cgen1:%08x\r\n", getreg32(BFLB_GLB_CGEN1_BASE));

View file

@ -245,12 +245,6 @@ void board_init(void)
console_init();
bl_show_log();
if (ret != 0) {
printf("flash init fail!!!\r\n");
}
bl_show_flashinfo();
#ifdef CONFIG_PSRAM
if (uhs_psram_init() < 0) {
while (1) {
@ -260,6 +254,12 @@ void board_init(void)
size_t heap_len = ((size_t)&__HeapLimit - (size_t)&__HeapBase);
kmem_init((void *)&__HeapBase, heap_len);
bl_show_log();
if (ret != 0) {
printf("flash init fail!!!\r\n");
}
bl_show_flashinfo();
printf("dynamic memory init success,heap size = %d Kbyte \r\n", ((size_t)&__HeapLimit - (size_t)&__HeapBase) / 1024);
printf("sig1:%08x\r\n", BL_RD_REG(GLB_BASE, GLB_UART_CFG1));