设备树支持&多块内存初步支持
This commit is contained in:
@@ -16,7 +16,7 @@ extern void *app_start_addr;
|
||||
#ifdef CONFIG_EX_RAM_SIZE
|
||||
static umword_t mm_bitmap[ROUND(CONFIG_EX_RAM_SIZE, MK_PAGE_SIZE) / (sizeof(umword_t) * 8) + 1];
|
||||
#else
|
||||
static umword_t mm_bitmap[ROUND(CONFIG_KNL_DATA_SIZE, MK_PAGE_SIZE) / (sizeof(umword_t) * 8) + 1];
|
||||
static umword_t mm_bitmap[ROUND(CONFIG_SYS_DATA_SIZE, MK_PAGE_SIZE) / (sizeof(umword_t) * 8) + 1];
|
||||
#endif
|
||||
static void *mm_page_alloc(int page_nr)
|
||||
{
|
||||
|
||||
@@ -58,7 +58,7 @@ add_custom_target(
|
||||
COMMAND
|
||||
mkdir -p ${CMAKE_SOURCE_DIR}/build/output
|
||||
COMMAND
|
||||
cp init.bin ${CMAKE_SOURCE_DIR}/build/output/init
|
||||
cp init.bin ${CMAKE_SOURCE_DIR}/build/output/cpio/init
|
||||
COMMAND
|
||||
cp ${CMAKE_CURRENT_LIST_DIR}/src/init.cfg ${CMAKE_SOURCE_DIR}/build/output/cpio/
|
||||
COMMAND
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#include <u_util.h>
|
||||
#if !IS_ENABLED(CONFIG_MMU)
|
||||
#define HEAP_SIZE 2048
|
||||
#define STACK_SIZE (1024 + 512)
|
||||
#define STACK_SIZE (2048)
|
||||
|
||||
#if defined(__CC_ARM)
|
||||
#define HEAP_ATTR SECTION("HEAP") __attribute__((zero_init))
|
||||
|
||||
@@ -4,7 +4,7 @@ void mpu_test(void)
|
||||
{
|
||||
printf("start mpu test...\n");
|
||||
// mpu保护测试
|
||||
int *test = ((int *)CONFIG_KNL_DATA_ADDR);
|
||||
int *test = ((int *)CONFIG_SYS_DATA_ADDR);
|
||||
*test = 1;
|
||||
printf("cpu don't support mpu.\n");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user