Port-arm archive

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

Re: clk_set_parent() by name ?



On Tue, 20 Mar 2018, Manuel Bouyer wrote:

but pushing driver-specific clock setup in the ccu also looks wrong
to me, and could appear as black magic.

It's not driver specific. The TCON needs a clock input at a certain frequency and requests it from the clk driver. The clk driver for that soc knows how to program the video PLL to supply a clock at that frequency.

It seems they have display-specific clock drivers (e.g.
./drivers/clk/sunxi/clk-sun4i-display.c
./drivers/clk/sunxi/clk-sun4i-tcon-ch1.c
)
So we'll probably have to do the same, instead of using the
PLL generic drivers.
This will also probably need an update of the clock interface (like
reference counts for enable/disable, "exclusive" clocks, maybe others).

Those are old clock drivers, you should look in drivers/clk/sunxi-ng for the new style bindings (which is all we support in NetBSD).

But yeah, you can see them on the tcon nodes, named by the "clock-output-names" property. It looks like those clocks use the "tcon-ch0" xref as their parent, and are used by CH0. The "tcon-ch1" xref is used directly by CH1.

Home | Main Index | Thread Index | Old Index