]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm/ast: Find VBIOS mode from regular display size
authorThomas Zimmermann <tzimmermann@suse.de>
Fri, 31 Jan 2025 09:21:08 +0000 (10:21 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 May 2025 09:13:42 +0000 (11:13 +0200)
commita7685bb8fedf5edd39f1e5d58e1d493f8ae2886f
treed21c77e2c5efe5bdf9529cc192f0d77c66846313
parent7f6ecc8542b47b55515159c777fc0fd8760b0277
drm/ast: Find VBIOS mode from regular display size

[ Upstream commit c81202906b5cd56db403e95db3d29c9dfc8c74c1 ]

The ast driver looks up supplied display modes from an internal list of
display modes supported by the VBIOS.

Do not use the crtc_-prefixed display values from struct drm_display_mode
for looking up the VBIOS mode. The fields contain raw values that the
driver programs to hardware. They are affected by display settings like
double-scan or interlace.

Instead use the regular vdisplay and hdisplay fields for lookup. As the
programmed values can now differ from the values used for lookup, set
struct drm_display_mode.crtc_vdisplay and .crtc_hdisplay from the VBIOS
mode.

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250131092257.115596-9-tzimmermann@suse.de
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/ast/ast_mode.c