clk: sunxi-ng: a64: force select PLL_MIPI in TCON0 mux
authorRoman Beranek <me@crly.cz>
Fri, 5 May 2023 05:21:07 +0000 (07:21 +0200)
committerJernej Skrabec <jernej.skrabec@gmail.com>
Thu, 18 May 2023 21:07:09 +0000 (23:07 +0200)
commitca1170b69968233b34d26432245eddf7d265186b
treeb9a8688dc91ea98cb6833a06999f7f1e80198ae8
parentac9a78681b921877518763ba0e89202254349d1b
clk: sunxi-ng: a64: force select PLL_MIPI in TCON0 mux

TCON0's source clock can be fed from either PLL_MIPI, or PLL_VIDEO0(2X),
however MIPI DSI output only seems to work when PLL_MIPI is selected and
thus the choice must be hardcoded in.

Currently, this driver can't propagate rate change from N-K-M clocks
(such as PLL_MIPI) upwards. This prevents PLL_VIDEO0 from participating
in setting of the TCON0 data clock rate, limiting the precision with
which a target pixel clock can be matched.

For outputs with fixed TCON0 divider, that is DSI and LVDS, the dotclock
can deviate up to 8% off target.

Signed-off-by: Roman Beranek <me@crly.cz>
Reviewed-by: Jernej Skrabec <jernej.skrabec@gmail.com>
Acked-by: Maxime Ripard <maxime@cerno.tech>
Link: https://lore.kernel.org/r/20230505052110.67514-2-me@crly.cz
Signed-off-by: Jernej Skrabec <jernej.skrabec@gmail.com>
drivers/clk/sunxi-ng/ccu-sun50i-a64.c