设为首页 加入收藏

TOP

U-Boot中fdt命令的使用
2014-11-24 13:09:55 来源: 作者: 【 】 浏览:1
Tags:U-Boot fdt 命令 使用

依linux community的要求,从linux-3.5后,新提交的code必须对device tree进行支持。下面介绍如何使u-boot支持device tree,以及fdt命令的使用。


1. u-boot对fdt(flattened device tree)的支持。


实现:只要加入



把device tree blob (dtb)文件下载到内存里


-----------------------------------------


U-Boot> tftpboot 0x71000000 bshen/test-ek.dtb


-----------------------------------------


设置fdt的地址


-----------------------------------------


U-Boot> fdt addr 0x71000000


-----------------------------------------


然后就可以使用其余的命令参数了


-----------------------------------------


U-Boot> fdt header
magic: 0xd00dfeed
totalsize: 0x1887 (6279)
off_dt_struct: 0x38
off_dt_strings: 0x1648
off_mem_rsvmap: 0x28
version: 17
last_comp_version: 16
boot_cpuid_phys: 0x0
size_dt_strings: 0x23f
size_dt_struct: 0x1610
number mem_rsv: 0x0


-----------------------------------------


fdt print 不跟参数时,打印出整颗树


fdt print加path参数,则打path内容,如下(其中/memory是path):


-----------------------------------------


U-Boot> fdt print /memory
memory {
device_type = "memory";
reg = <0x70000000 0x4000000>;
};


-----------------------------------------


】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
分享到: 
上一篇利用Java泛型实现简单的泛型方法 下一篇ArcGIS for Android离线数据编辑..

评论

帐  号: 密码: (新用户注册)
验 证 码:
表  情:
内  容:

·MySQL 安装及连接-腾 (2025-12-25 06:20:28)
·MySQL的下载、安装、 (2025-12-25 06:20:26)
·MySQL 中文网:探索 (2025-12-25 06:20:23)
·Shell脚本:Linux Sh (2025-12-25 05:50:11)
·VMware虚拟机安装Lin (2025-12-25 05:50:08)