d3ara1n / dtb_parser

no std but alloc depended device tree parsing lib

Home Page:https://docs.rs/dtb_parser

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

dtb_parser

Usage

pub const BLOB: &[u8] = include_bytes!("device.dtb");

fn main() {
    let tree = DeviceTree::from_bytes(BLOB).unwrap();
    println!("{}", tree);

    assert!(!matches!(tree.find_node("/soc/pci@30000000"), None));
}

TODO

  • Tree&Node parsing
  • Property with inherited value (#address-cells etc)
  • Display trait for the whole tree (output has subtle differences with dts mainly in values presentation which affected by #<specifier>-cells)
  • PHandle binding
  • Nexus node and specifier mapping
  • The situation when #address-cells value set to 3
  • Interrupt values

About

no std but alloc depended device tree parsing lib

https://docs.rs/dtb_parser


Languages

Language:Rust 100.0%