I am trying to setup a driver for an embedded PowerPC board, and the correct way to do this today is to use the OpenFirmware Device Tree datastructure (the .dtb file, compiled from a .dts file). Creating a tree is pretty easy, but how do I get my device driver to find its node and the data in it? I have not managed to find any good reference on this, and books like "Linux Device Drivers" are too much into x86 land to be of much help for device trees that mostly pertain to Power Architecture-based machines (arch powerpc in the Linux kernel terminology).
There seems to be very little documentation available, especially on the side of doing drivers. talked to a long-time Linux kernel developer I know, and his advice was essentially to look at the code of other drivers.
some background reading I found: Grant Likely presentation, Grant Likely Linux Symposium paper, a fairly good overview of the data structure
The most pervasive use of the open firmware system is found in the Freescale fsl_x.c drivers in the arch/powerpc/ tree in the Linux kernel, more recent than 2.6.16.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With