@@ -186,7 +186,7 @@ board description itself.
186186
187187Here's a simplified example of what a generic device tree might look like:
188188
189- ``` dts
189+ ``` sh
190190/dts-v1/;
191191
192192/ {
@@ -267,7 +267,7 @@ but instead of the device self-reporting, the platform description reports it.
267267
268268### ` memory@80000000 { ... } `
269269
270- ``` dts
270+ ``` sh
271271memory@80000000 {
272272 device_type = " memory" ;
273273 reg = < 0x80000000 0x40000000> ; /* 1 GB * /
@@ -286,7 +286,7 @@ So the kernel learns: "RAM lives at `0x80000000` and is 1 GiB long."
286286
287287### ` cpus { ... } and cpu@0 { ... } `
288288
289- ``` dts
289+ ``` sh
290290cpus {
291291 # address-cells = <1>;
292292 # size-cells = <0>;
@@ -319,7 +319,7 @@ This block is where embedded DTs get interesting because this is where devices
319319within the SoC interact with each other, essentially defining the region where
320320the hardware devices are mapped into memory:
321321
322- ``` dts
322+ ``` sh
323323soc {
324324 compatible = " simple-bus" ;
325325 # address-cells = <1>;
@@ -350,7 +350,7 @@ defined here is a perfect example.
350350
351351#### ` uart0: serial@9000000 { ... } `
352352
353- ``` dts
353+ ``` sh
354354uart0: serial@9000000 {
355355 compatible = " ns16550a" ;
356356 reg = < 0x09000000 0x1000> ;
@@ -381,7 +381,7 @@ to the UART registers.
381381trees, interrupts are almost always described relative to an interrupt
382382controller, often looking like:
383383
384- ``` dts
384+ ``` sh
385385interrupt-parent = < & gic> ;
386386interrupts = < 0 37 4> ; /* type, number, flags * /
387387```
@@ -395,7 +395,7 @@ Some drivers need to know the input clock to compute
395395In [ newer device trees] ( https://android.googlesource.com/kernel/msm/+/android-7.1.0_r0.2/Documentation/devicetree/bindings/clock/sunxi.txt#78 ) ,
396396you'll often see this modeled more explicitly using the common clock framework:
397397
398- ``` dts
398+ ``` sh
399399clocks = < & osc24m> ;
400400clock-names = " uart" ;
401401```
0 commit comments