public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [RFC] fdt expert advice needed
@ 2009-01-30 21:11 Matthias Fuchs
  2009-01-30 21:18 ` Scott Wood
  0 siblings, 1 reply; 5+ messages in thread
From: Matthias Fuchs @ 2009-01-30 21:11 UTC (permalink / raw)
  To: u-boot

Hi FDT experts,

some time ago I posted a patch to fix U-Boot's approach to
set all ns16550 compatible nodes' clock-frequency property
in ppc4xx device tree's:

do_fixup_by_compat_u32(blob, "ns16550", "clock-frequency", gd->uart_clk, 1);

Typically this works fine. It is intended to configure all CPU internal UART's clock.
We have some additional UARTs attached to an external bus. From the device
tree's point of view they have a different path, but are also ns16550 compatible.

So the above line will also overwrite thier clock-frequency. This must not be done,
because they have a separate external clock and the value in the device tree is correct!

Now I want to replace the above code to only touch the ns16550 compatible nodes
that are direct childs of /plb/opb. Not those under /plb/ebc and even not those under 
/plb/opb/ebc. This is not easy to do with the fdt API. Below you find my first and dirty
hack.

Isn't there a more simple way to do so? Don't bother me about the printf, variable names etc.
It's just for discussion.

Please tell me if I have to explain my code :-)

Matthias

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-02-02 17:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-30 21:11 [U-Boot] [RFC] fdt expert advice needed Matthias Fuchs
2009-01-30 21:18 ` Scott Wood
2009-01-30 21:22   ` Scott Wood
2009-02-01 21:30     ` Matthias Fuchs
2009-02-02 17:09       ` Scott Wood

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox