TI论坛
直播中

李雨充

7年用户 210经验值
私信 关注
[问答]

am335x dts文件疑惑

am335x在arch/ARM/boot/dts目录下有2个dts文件
am335x-evm.dts和am33xx.dtsi
am335-evm.dts里面应该是配置各个驱动的dts文件,那么am33xx.dtsi里面的内容都是用来做什么的?我看了下里面好多模块的status都是“disabled.”

回帖(3)

吴思莹

2018-5-15 09:01:57
am33xx.dtsi文件中都是对于SoC中所有模块最基础架构的定义,比如寄存器地址,中断号之类的,这些共性的东西是不会随着板子设计应用的改变而改变的。
而am335x-evm.dts文件中,是根据自己的实际办卡应用中做的配置,简而言之,用了哪些接口,使用怎样的pinmux配置,这种类型的信息都会体现在这个板级配置文件中,并且最终在这里吧status修改成为okay生效。
一般来说,我们不建议修改am33xx.dtsi这种SoC架构基础文件,你只要修改你自己的板级配置文件DTS就可以了。
举报

李雨充

2018-5-15 09:18:53
引用: hwjj940056201 发表于 2018-5-15 09:01
am33xx.dtsi文件中都是对于SoC中所有模块最基础架构的定义,比如寄存器地址,中断号之类的,这些共性的东西是不会随着板子设计应用的改变而改变的。
而am335x-evm.dts文件中,是根据自己的实际办卡应用中做的配置,简而言之,用了哪些接口,使用怎样的pinmux配置,这种类型的信息都会体现在这个板级配置文件中,并且最终在 ...

基本我理解是说两个文件是合并一起的,am33xx.dtsi里面的内容是基础模块的配置,和am335x-evm.dts配合生成最后的dtb文件。但是在dtsi中的下面这个段是用来做什么的?其中没有mmc,mmc也可以工作。
aliases [
i2c0 = &i2c0;
i2c1 = &i2c1;
i2c2 = &i2c2;
serial0 = &uart0;
serial1 = &uart1;
serial2 = &uart2;
serial3 = &uart3;
serial4 = &uart4;
serial5 = &uart5;
d_can0 = &dcan0;
d_can1 = &dcan1;
u***0 = &u***0;
u***1 = &u***1;
phy0 = &u***0_phy;
phy1 = &u***1_phy;
ethernet0 = &cpsw_emac0;
ethernet1 = &cpsw_emac1;
];
举报

吴思莹

2018-5-15 09:31:52
引用: uweuewyfydsf 发表于 2018-5-15 09:18
基本我理解是说两个文件是合并一起的,am33xx.dtsi里面的内容是基础模块的配置,和am335x-evm.dts配合生成最后的dtb文件。但是在dtsi中的下面这个段是用来做什么的?其中没有mmc,mmc也可以工作。
aliases [
i2c0 = &i2c0;

http://stackoverflow.com/questions/17738709/dts-file-explanation-aliases
In the aliases section of a DTS, we see entries of the format
property = &label;
Each of the entries consists of :
a. property -- A new property defined here.
b. &label -- Complete DTS path to the node referenced by the label.
It basically assigns the value of b to a. Henceforth, the long-name to the node identified by the label can be accessed using the shorthand property.
Note that the RHS of this assignment is using labels and NOT the short-names of the individual nodes. Just like a label in C code refers to an instruction on the line where it is defined, a labelin DTS refers to the individual node (using its complete long path) that is defined on that line.
For example, considering the following DTS,
lxr.free-electrons.com/source/arch/powerpc/boot/dts/mpc8313erdb.dts
举报

更多回帖

发帖
×
20
完善资料,
赚取积分