在.dts文件中对设备及其属性的描述通常如以下这样:
/ {
compatible = "acme, coyotes-revenge";
#address-cells = <1>;
#size-cells = <1>;
...
cpus {
#address-cells = <1>;
#size-cells = <0>;
cpu@0 {
compatible = "arm, cortex-a9";
reg = <0>;
};
cpu@1 {
compatible = "arm, cortex-a9";
reg = <1>;
};
};
serial1@101f0000 {
compatible = "arm,pl1011";
reg = <0x101f0000 0x1000>;
interrupts = < 1 0 >;
};
...
external-bus {
#address-cells = <2>;
#size-cells = <1>;
ranges = <0 0 0x10100000 0x1000 // ChipSelect 1, Ethernet
1 0 0x10160000 0x1000 // ChipSelect 2, i2c controller
2 0 0x30000000 0x100000