Skip to content

Repository files navigation

tree-sitter-devicetree

Devicetree grammar for tree-sitter. The grammar is directly ported from the Device Tree Compiler (dtc).

It also has (limited) support for the C preprocessor grammar. The goal here is to be able to parse all Devicetree Source files in the Linux kernel source tree. The test script can be used to verify this:

tree-sitter generate
./test/parse.sh /path/to/linux/

Copyright (C) 2026 Waqar Hameed and the tree-sitter-devictree contributors.

Releases

Packages

Contributors

Languages