drm/bridge: lt9611: fix clock calculation
authorDmitry Baryshkov <dmitry.baryshkov@linaro.org>
Wed, 18 Jan 2023 08:16:50 +0000 (10:16 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 08:33:14 +0000 (09:33 +0100)
commit30ef50ccdab38fa20e67c949eeafc21b6194bd27
treeb3f308c44b2ce6deb718f1d7d7bbd0b4f46ee53e
parent59646dabe92d2170863b3faade15380645ad9a3f
drm/bridge: lt9611: fix clock calculation

[ Upstream commit 2576eb26494eb0509dd9ceb0cd27771a7a5e3674 ]

Instead of having several fixed values for the pcr register, calculate
it before programming. This allows the bridge to support most of the
display modes.

Fixes: 23278bf54afe ("drm/bridge: Introduce LT9611 DSI to HDMI bridge")
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20230118081658.2198520-6-dmitry.baryshkov@linaro.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/bridge/lontium-lt9611.c