uboot 打开log 的 方法

uboot 版本

commit f919c3a889f0ec7d63a48b5d0ed064386b0980bd (HEAD -> v2024.10, tag: v2024.10)

Author: Tom Rini <trini@konsulko.com>

Date: Mon Oct 7 08:54:35 2024 -0600

Prepare v2024.10

Signed-off-by: Tom Rini <trini@konsulko.com>

开启的选项:

CONFIG_DEBUG_UART=y

git diff include/log.h

diff --git a/include/log.h b/include/log.h

index fc0d598447..908f9c015f 100644

--- a/include/log.h

+++ b/include/log.h

@@ -184,6 +184,7 @@ int _log_buffer(enum log_category_t cat, enum log_level_t level,

#define log_io(_fmt...) log(LOG_CATEGORY, LOGL_DEBUG_IO, ##_fmt)

#define log_cont(_fmt...) log(LOGC_CONT, LOGL_CONT, ##_fmt)

+#define LOG_DEBUG

#ifdef LOG_DEBUG

#define _LOG_DEBUG LOGL_FORCE_DEBUG

#ifndef DEBUG

没有开启log时:

No serial driver found

resetting ...

reset not supported yet

ERROR ### Please RESET the board

开启log打印之后

spl_early_init

size=30, ptr=30, limit=4000: 801dc000

common/malloc_simple.c:26-alloc_simple() size=30, ptr=60, limit=4000: common/malloc_simple.c:47-malloc_simple() 801dc030

common/malloc_simple.c:26-alloc_simple() size=98, ptr=f8, limit=4000: common/malloc_simple.c:47-malloc_simple() 801dc060

drivers/core/lists.c:216-lists_bind_fdt() bind node chosen

drivers/core/lists.c:221-lists_bind_fdt() Device 'chosen' has no compatible string

common/malloc_simple.c:26-alloc_simple() size=30, ptr=128, limit=4000: common/malloc_simple.c:47-malloc_simple() 801dc0f8

No serial driver found

resetting ...

reset not supported yet

ERROR ### Please RESET the board

相关推荐
大橙子额5 分钟前
【解决报错】Cannot assign to read only property ‘exports‘ of object ‘#<Object>‘
前端·javascript·vue.js
_F_y15 分钟前
C++重点知识总结
java·jvm·c++
打工的小王17 分钟前
Spring Boot(三)Spring Boot整合SpringMVC
java·spring boot·后端
毕设源码-赖学姐18 分钟前
【开题答辩全过程】以 高校体育场馆管理系统为例,包含答辩的问题和答案
java·spring boot
我真会写代码19 分钟前
SSM(指南一)---Maven项目管理从入门到精通|高质量实操指南
java·spring·tomcat·maven·ssm
vx_Biye_Design20 分钟前
【关注可免费领取源码】房屋出租系统的设计与实现--毕设附源码40805
java·spring boot·spring·spring cloud·servlet·eclipse·课程设计
DN金猿25 分钟前
接口路径正确,请求接口却提示404
java·tomcat
Maynor9961 小时前
OpenClaw 玩家必备:用 AI 自动追踪社区最新动态
java·服务器·人工智能
堕2741 小时前
java数据结构当中的《排序》(一 )
java·数据结构·排序算法
WooaiJava1 小时前
AI 智能助手项目面试技术要点总结(前端部分)
javascript·大模型·html5