A data structure for describing hardware. passed in boot time to kernel
Questions tagged [device-tree]
137 questions
43
votes
2 answers
Is it possible to get the information for a device tree using /sys of a running kernel?
Commonly for arm systems, device trees supply hardware information to the kernel (Linux). These device trees exist as dts (device tree source) files that are compiled and loaded to the kernel. Problem is that I do not have access to such a dts file,…
humanityANDpeace
- 13,722
- 13
- 61
- 107
29
votes
2 answers
Why do embedded systems need device tree while pcs don't?
When booting a kernel in an embedded device, you need to supply a device tree to the Linux kernel, while booting a kernel on a regular x86 pc doesn't require a device tree -- why?
As I understand, on an x86 pc the kernel "probes" for hardware…
MOHAMMAD RASIM
- 460
- 5
- 11
29
votes
2 answers
How to list the kernel Device Tree
I am using an embedded Arm with a Debian build. How does one list the compiled devices from the device tree? I want to see if a device is already supported.
For those reading this, the "Device Tree" is a specification/standard for adding devices to…
Xofo
- 619
- 1
- 8
- 19
15
votes
2 answers
How do I tell which device tree blob (dtb file) I'm using?
I'm working with TS-4900, an embedded 'Computer on Module' plugged into a baseboard, running Yocto Linux. It uses U-Boot to start, and supposedly basing on the model of the baseboard it chooses the right dtb file to start, and possibly if it fails…
SF.
- 2,891
- 2
- 25
- 26
12
votes
1 answer
Meaning of an ampersand prefix in a device tree
I am looking at a DTS file which tries to specify different nodes, but interestingly I find a few nodes having different style of nomenclature.
/ {
model = "TI AM335x BeagleBone Black";
compatible = "ti,am335x-bone-black", "ti,am335x-bone",…
kakeh
- 483
- 7
- 16
11
votes
3 answers
What is a device tree and a device tree blob?
What exactly is a device tree, and a device tree blob? Where can I get its source code for a particular linux version? I found such name while running linux on xilinx chips (having ARM 9), for example: here
gpuguy
- 1,316
- 12
- 29
- 45
10
votes
1 answer
How to debug a driver failing to bind to a device on Linux?
I am trying to figure out why the following device is not setup to its driver on my Creator CI20. For reference I am using a Linux kernel v4.13.0 and doing the compilation locally:
make ARCH=mips ci20_defconfig
make -j8 ARCH=mips…
malat
- 2,708
- 4
- 27
- 47
8
votes
3 answers
How does kernel know which device tree to load?
Device tree is used at runtime on ARM devices to identify and load correct drivers with its configuration. But when I look into loaded DT at /proc/device-tree on my phone for example, there are many configurations unrelated to actuall platform. For…
user32569
- 193
- 1
- 3
7
votes
1 answer
Applying device tree overlay
I have a device based on imx233-Olinuxino-Nano.
The Arch Linux Arm distro boots and works.
However, there is a slave device on my board that is connected to SPI of CPU. It is supported by kernel, but, obviously, generic device tree for Olinuxino…
Alexandr Zarubkin
- 173
- 5
6
votes
1 answer
current question: How can I decompile an arm firmware file, to get the device tree file?
I am trying to flash libreelec on an android TV box without having an image I could throw in the libreelec toaster. On the RPi it was quite simple, here I guess I have to compile stuff, I don't really have the answer for.
There is an Image for the…
Bogotrax
- 83
- 1
- 5
6
votes
2 answers
Device Trees: Difference between labels and aliases?
In the file imx6qdl.dtsi is the following definition of gpio nodes (somewhat shortened):
gpio1: gpio@0209c000 {
[...]
};
gpio2: gpio@020a0000 {
[...]
};
[...]
gpio7: gpio@020b4000 {
[...]
};
But also in this file, the aliases node…
happyMOOyear
- 161
- 1
- 2
5
votes
2 answers
What are the values of the device tree interrupts property?
I'm trying to understand the device tree interrupts property and can not find a good explanation.
For example if there is a node with the following lines:
interrupt-parent = <&gpio5>;
interrupts = <9 0>;
How do I figure out what the magic numbers…
sfrank
- 91
- 1
- 1
- 6
5
votes
2 answers
how to merge device tree overlays to a single .dtb at build time?
My board boots via U-Boot and AFAIK that bootloader does not support device tree overlays, so I'm probably forced to generate a single, static .dtb will all relevant overlays (and settings??) already applied to it. In principle that would be okay…
Udo G
- 1,123
- 3
- 12
- 27
5
votes
3 answers
What are the two values inside angle brackets < > in a device tree .dts file?
Following is the code snippet in a device tree file:
flash@0 {
compatible = "n25q128";
reg = <0x0>;
spi-max-frequency = <50000000>;
#address-cells = <1>;
#size-cells…
gpuguy
- 1,316
- 12
- 29
- 45
3
votes
0 answers
Loading a kernel module at run time using "compatible" property of device node in device-tree
If I know the "compatible" property string of a device(from the device tree), can I use it at runtime to load the corresponding kernel driver module? I do not have access to the driver source. I am using a linux kernel. Thanks!
wishywashy
- 63
- 4