Commit c0436604 authored by Adam Ford's avatar Adam Ford Committed by sanglipeng
Browse files

drm/bridge: adv7533: Fix adv7533_mode_valid for adv7533 and adv7535

stable inclusion
from stable-v5.10.180
commit f8d28cecf2100e2fd0677812a1af70f6cf2e10fb
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I8DDFN

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=f8d28cecf2100e2fd0677812a1af70f6cf2e10fb



--------------------------------

[ Upstream commit ee0285e1 ]

When dynamically switching lanes was removed, the intent of the code
was to check to make sure that higher speed items used 4 lanes, but
it had the unintended consequence of removing the slower speeds for
4-lane users.

This attempts to remedy this by doing a check to see that the
max frequency doesn't exceed the chip limit, and a second
check to make sure that the max bit-rate doesn't exceed the
number of lanes * max bit rate / lane.

Fixes: 9a0cdcd6 ("drm/bridge: adv7533: remove dynamic lane switching from adv7533 bridge")
Reviewed-by: default avatarRobert Foss <rfoss@kernel.org>
Signed-off-by: default avatarAdam Ford <aford173@gmail.com>
Signed-off-by: default avatarRobert Foss <rfoss@kernel.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20230319125524.58803-1-aford173@gmail.com


Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarsanglipeng <sanglipeng1@jd.com>
parent 1ccfad54
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment