如果编译报错编出来的lk太大了,当然可以改分区表,但是一般不建议这么做
纯粹经验,如果把lk多余的打印去掉,如果lk大小超出的不多,就可以解决
patch分享如下,修改lk代码
diff --git a/lib/mblock/mblock_v2.c b/lib/mblock/mblock_v2.c
index 2b5c1fc..1fce70d 100644
--- a/lib/mblock/mblock_v2.c
+++ b/lib/mblock/mblock_v2.c
@@ -237,11 +237,11 @@
end = limit < (start + sz) ? limit : (start + sz);
reserved_addr = (end - reserved_size);
reserved_addr &= ~(align - 1);
- dprintf(CRITICAL, "mblock[%d].start: 0x%llx, sz: 0x%llx, limit: 0x%llx, max_addr: 0x%llx, target: %d, reserved_addr: 0x%llx,"
+ dprintf(INFO, "mblock[%d].start: 0x%llx, sz: 0x%llx, limit: 0x%llx, max_addr: 0x%llx, target: %d, reserved_addr: 0x%llx,"
"reserved_size: 0x%llx\n",
i, start, sz, limit, max_addr,
target, reserved_addr, reserved_size);
- dprintf(CRITICAL, "mblock_reserve dbg[%d]: %d, %d, %d, %d\n",
+ dprintf(INFO, "mblock_reserve dbg[%d]: %d, %d, %d, %d\n",
i, (reserved_addr + reserved_size <= start + sz),
(reserved_addr >= start),
(start + sz > max_addr),
@@ -352,14 +352,14 @@
for (i = 0; i < mblock_info->mblock_num; i++) {
start = mblock_info->mblock[i].start;
sz = mblock_info->mblock[i].size;
- dprintf(CRITICAL, "mblock_reserve [%d].start: 0x%llx, sz: 0x%llx\n",
+ dprintf(INFO, "mblock_reserve [%d].start: 0x%llx, sz: 0x%llx\n",
i, start, sz);
}
for (i = 0; i < mblock_info->reserved_num; i++) {
start = mblock_info->reserved[i].start;
sz = mblock_info->reserved[i].size;
- dprintf(CRITICAL, "mblock_reserve-R[%d].start: 0x%llx, sz: 0x%llx map:%d name:%s\n",
+ dprintf(INFO, "mblock_reserve-R[%d].start: 0x%llx, sz: 0x%llx map:%d name:%s\n",
i, start, sz, mblock_info->reserved[i].mapping, mblock_info->reserved[i].name);
}
diff --git a/project/S96116AA1.mk b/project/S96116AA1.mk
index ee463dd..ca0e893 100644
--- a/project/S96116AA1.mk
+++ b/project/S96116AA1.mk
@@ -25,7 +25,7 @@
MTK_SEC_FASTBOOT_UNLOCK_SUPPORT = yes
SPM_FW_USE_PARTITION = yes
BOOT_LOGO := hdplus1520
-DEBUG := 2
+DEBUG := 0
#DEFINES += WITH_DEBUG_DCC=1
DEFINES += WITH_DEBUG_UART=1
#DEFINES += WITH_DEBUG_FBCON=1
diff --git a/project/S96116BA1.mk b/project/S96116BA1.mk
index 970d699..6e23225 100644
--- a/project/S96116BA1.mk
+++ b/project/S96116BA1.mk
@@ -25,7 +25,7 @@
MTK_SEC_FASTBOOT_UNLOCK_SUPPORT = yes
SPM_FW_USE_PARTITION = yes
BOOT_LOGO := hdplus1520
-DEBUG := 2
+DEBUG := 0
#DEFINES += WITH_DEBUG_DCC=1
DEFINES += WITH_DEBUG_UART=1
#DEFINES += WITH_DEBUG_FBCON=1
diff --git a/target/S96116AA1/rules.mk b/target/S96116AA1/rules.mk
index a8f7b96..e3f2d0d 100644
--- a/target/S96116AA1/rules.mk
+++ b/target/S96116AA1/rules.mk
@@ -36,7 +36,7 @@
HAVE_CACHE_PL310 := no
MTK_LM_MODE := yes
MTK_FASTBOOT_SUPPORT := yes
-LK_PROFILING := yes
+LK_PROFILING := no
DEVICE_TREE_SUPPORT := yes
MTK_DLPT_SUPPORT := yes
MTK_USB2JTAG_SUPPORT := yes
diff --git a/target/S96116BA1/rules.mk b/target/S96116BA1/rules.mk
index a8f7b96..e3f2d0d 100644
--- a/target/S96116BA1/rules.mk
+++ b/target/S96116BA1/rules.mk
@@ -36,7 +36,7 @@
HAVE_CACHE_PL310 := no
MTK_LM_MODE := yes
MTK_FASTBOOT_SUPPORT := yes
-LK_PROFILING := yes
+LK_PROFILING := no
DEVICE_TREE_SUPPORT := yes
MTK_DLPT_SUPPORT := yes
MTK_USB2JTAG_SUPPORT := yes