Best practice device tree design for display subsystems/DRM

Grant Likely grant.likely at secretlab.ca
Fri Jul 5 19:51:04 EST 2013


On Fri, Jul 5, 2013 at 10:34 AM, Sebastian Hesselbarth
<sebastian.hesselbarth at gmail.com> wrote:
> So for the discussion, I can see that there have been some voting for
> super-node, some for node-to-node linking. Although I initially proposed
> super-nodes, I can also happily live with node-to-node linking alone.
>
> Either someone can give an example where one of the approaches will not
> work (i.MX, exynos?), Grant or one of the DRM maintainers has a
> preference, or we are stuck at the decision.

I tend to prefer a top-level super nodes with phandles to all of the
components that compose the device when there is no clear one device
that controls all the others. There is some precedence for that in
other subsystems (leds, asoc, etc). Sound in particular has a lot of
different bits and pieces that are interconnected with audio channels,
gpios, and other things that get quite complicated, so it is
convenient to have a single node that describes how they all fit
together *and* allows for a platform to use a completely different
device driver if required.

node-to-node linking works well if there an absolute 'master' can be
identified for the virtual device. ie. Ethernet MAC devices use a
"phy-device" property to link to the phy it requires. In that case it
is pretty clear that the Ethernet MAC is in charge and it uses the
PHY.

In either case it is absolutely required that the 'master' driver
knows how to find and wait for all the subservient devices before
probing can complete.

I know that isn't a solid answer, but you know the problem space
better than I. Take the above into account, make a decision and post a
binding proposal for review.

g.


More information about the devicetree-discuss mailing list