Port-arm archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Support for trees of clocks served by one clock manager



On Wed, 15 Aug 2018, Aymeric Vincent wrote:

Sure, the clock tree is in
sys/external/gpl2/dts/dist/arch/arm/boot/dts/socfpga.dtsi
and I include below a dump of the exact dtb I use for completeness.

Thanks, that helps a lot.

In order to avoid the loop, I could register all clocks as clock
managers but that's _very_ ugly (it works).

I think this is fine. Consider the binding docs:

https://www.kernel.org/doc/Documentation/devicetree/bindings/clock/clock-bindings.txt
https://www.kernel.org/doc/Documentation/devicetree/bindings/clock/altr_socfpga.txt

In the generic binding docs, there is no mention of searching for parent clock controllers. The cross reference from clock consumer contains the phandle of the clock controller and optional specifier.

For SoCFPGA platform, it looks like each node under clock is meant to be a separate clock device, and in socfpga.dtsi there are multiple "fixed-clock" nodes for which we already have a driver (dev/fdt/fixedclock.c).

Walking the tree to find the clock controller might work in this case but it is contrary to the binding docs and could cause issues in a scenario where we have nested clock controllers and are missing a driver for the child one.

Cheers,
Jared


Home | Main Index | Thread Index | Old Index