]> git.hungrycats.org Git - linux/commit
phy/rockchip: inno-hdmi: round fractal pixclock in rk3328 recalc_rate
authorZheng Yang <zhengyang@rock-chips.com>
Thu, 15 Jun 2023 17:10:19 +0000 (17:10 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 13 Sep 2023 07:48:35 +0000 (09:48 +0200)
commite9876c8873fc5ed7e9ecd93b2eef4cd631be8212
tree7b25756730be82505a82598debdab180bab975cb
parent7a35fe6478f71cd0ac7fd5c7ec71d2dcc0ac79d8
phy/rockchip: inno-hdmi: round fractal pixclock in rk3328 recalc_rate

[ Upstream commit d5ef343c1d62bc4c4c2c393af654a41cb34b449f ]

inno_hdmi_phy_rk3328_clk_recalc_rate() is returning a rate not found
in the pre pll config table when the fractal divider is used.
This can prevent proper power_on because a tmdsclock for the new rate
is not found in the pre pll config table.

Fix this by saving and returning a rounded pixel rate that exist
in the pre pll config table.

Fixes: 53706a116863 ("phy: add Rockchip Innosilicon hdmi phy")
Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
Link: https://lore.kernel.org/r/20230615171005.2251032-3-jonas@kwiboo.se
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/phy/rockchip/phy-rockchip-inno-hdmi.c