Skip to content

Instantly share code, notes, and snippets.

@TunaCici
Created June 28, 2023 18:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save TunaCici/03aaa31cab18d9c7720dfe1ae52d6db8 to your computer and use it in GitHub Desktop.
Save TunaCici/03aaa31cab18d9c7720dfe1ae52d6db8 to your computer and use it in GitHub Desktop.
[GNU/Linux] Decompile Device Tree Blob File /w device-tree-compiler

Install device-tree-decompiler

Using apt:

$ apt install device-tree-compiler

Using pacman:

pacman -S dtc

Usage

$ dtc -I dtb -O dts <IN-FILE-PATH> -o <OUT-FILE-PATH>

# -I dtb: Input format is Device Tree Blob (dtb)
# -O dts: Output format is Device Tree Structure (dts)
# <IN-FILE-PATH>: The *.dtb file you want to decompile
# -o <OUT-FILE-PATH>: The *.dts output file

# Ex. dtc -I dtb -O dts ./arm-virt.dtb -o ./output.dts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment