Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
| linux_device_trees [2018/11/18 10:29] – [Proper use of .dtsi files] rpjday | linux_device_trees [2018/12/11 13:03] (current) – [Internal wiki pages] rpjday | ||
|---|---|---|---|
| Line 3: | Line 3: | ||
| Stuff related to device trees and the Linux kernel, using examples from the current Linux kernel. | Stuff related to device trees and the Linux kernel, using examples from the current Linux kernel. | ||
| - | To do: | + | ===== TO DO ===== |
| * overlays | * overlays | ||
| + | * keywords (/plugin/, / | ||
| + | |||
| + | ===== MISC (for now) ===== | ||
| + | |||
| + | * "The unit-address must match the first address specified in the reg property of the node. If the node has no reg property, the @unit-address must be omitted and the node-name alone differentiates the node from other nodes at the same level in the tree. The binding for a particular bus may specify additional, more specific requirements for the format of reg and the unit-address." | ||
| ===== Some links ===== | ===== Some links ===== | ||
| Line 46: | Line 51: | ||
| * [[Device tree naming conventions]] | * [[Device tree naming conventions]] | ||
| * [[Proper device tree design]] | * [[Proper device tree design]] | ||
| + | * [[Device tree standard properties]] | ||
| + | * [[Device tree node requirements]] | ||
| * [[Comparing device trees with dtx_diff]] | * [[Comparing device trees with dtx_diff]] | ||
| + | * [[Hierarchical device files]] | ||
| - | ===== Proper device tree design ===== | ||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | ==== Examples of / | ||
| - | |||
| - | === imx6dl-tx6s-8034.dts === | ||
| - | |||
| - | < | ||
| - | #include " | ||
| - | #include " | ||
| - | |||
| - | / { | ||
| - | model = "Ka-Ro electronics TX6S-8034 Module"; | ||
| - | compatible = " | ||
| - | |||
| - | aliases { | ||
| - | display = & | ||
| - | ipu1 = &ipu1; | ||
| - | }; | ||
| - | |||
| - | cpus { | ||
| - | / | ||
| - | }; | ||
| - | </ | ||
| - | |||
| - | === imx6q-utilite-pro.dts === | ||
| - | |||
| - | < | ||
| - | #include < | ||
| - | #include " | ||
| - | |||
| - | / { | ||
| - | model = " | ||
| - | compatible = " | ||
| - | | ||
| - | ... | ||
| - | |||
| - | }; | ||
| - | |||
| - | /* | ||
| - | * A single IPU is not able to drive both display interfaces available on the | ||
| - | * Utilite Pro at high resolution due to its bandwidth limitation. Since the | ||
| - | * tfp410 encoder is wired up to IPU1, sever the link between IPU1 and the | ||
| - | * SoC-internal Designware HDMI encoder forcing the latter to be connected to | ||
| - | * IPU2 instead of IPU1. | ||
| - | */ | ||
| - | / | ||
| - | / | ||
| - | / | ||
| - | / | ||
| - | </ | ||
| - | |||
| - | |||
| - | ==== Examples of / | ||
| - | |||
| - | === imx6qp.dtsi === | ||
| - | |||
| - | < | ||
| - | #include " | ||
| - | |||
| - | / { | ||
| - | soc { | ||
| - | | ||
| - | ... | ||
| - | | ||
| - | }; | ||
| - | |||
| - | &fec { | ||
| - | / | ||
| - | interrupts = <0 118 IRQ_TYPE_LEVEL_HIGH>, | ||
| - | <0 119 IRQ_TYPE_LEVEL_HIGH>; | ||
| - | }; | ||
| - | </ | ||
| - | |||
| - | === imx6ul-tx6ul-mainboard.dts === | ||
| - | |||
| - | < | ||
| - | #include " | ||
| - | #include " | ||
| - | |||
| - | / { | ||
| - | model = "Ka-Ro electronics TXUL-0010 Module on TXUL Mainboard"; | ||
| - | compatible = " | ||
| - | |||
| - | aliases { | ||
| - | lcdif_24bit_pins_a = & | ||
| - | mmc0 = & | ||
| - | / | ||
| - | serial2 = &uart3; | ||
| - | serial4 = &uart5; | ||
| - | }; | ||
| - | / | ||
| - | }; | ||
| - | |||
| - | ... | ||
| - | |||
| - | &usdhc1 { | ||
| - | pinctrl-0 = <& | ||
| - | non-removable; | ||
| - | / | ||
| - | cap-sdio-irq; | ||
| - | }; | ||
| - | |||
| - | &uart1 { | ||
| - | pinctrl-0 = <& | ||
| - | / | ||
| - | }; | ||
| - | |||
| - | &uart2 { | ||
| - | pinctrl-0 = <& | ||
| - | / | ||
| - | status = " | ||
| - | }; | ||
| - | </ | ||