Skip to content

Commit 1517c30

Browse files
committed
Change dts blocks to sh blocks so they render properly on chirpy's template
1 parent b0ad151 commit 1517c30

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

_posts/2025-12-28-journey-into-device-trees.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ board description itself.
186186

187187
Here'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
271271
memory@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
290290
cpus {
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
319319
within the SoC interact with each other, essentially defining the region where
320320
the hardware devices are mapped into memory:
321321

322-
```dts
322+
```sh
323323
soc {
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
354354
uart0: serial@9000000 {
355355
compatible = "ns16550a";
356356
reg = <0x09000000 0x1000>;
@@ -381,7 +381,7 @@ to the UART registers.
381381
trees, interrupts are almost always described relative to an interrupt
382382
controller, often looking like:
383383

384-
```dts
384+
```sh
385385
interrupt-parent = <&gic>;
386386
interrupts = <0 37 4>; /* type, number, flags */
387387
```
@@ -395,7 +395,7 @@ Some drivers need to know the input clock to compute
395395
In [newer device trees](https://android.googlesource.com/kernel/msm/+/android-7.1.0_r0.2/Documentation/devicetree/bindings/clock/sunxi.txt#78),
396396
you'll often see this modeled more explicitly using the common clock framework:
397397

398-
```dts
398+
```sh
399399
clocks = <&osc24m>;
400400
clock-names = "uart";
401401
```

0 commit comments

Comments
 (0)