]> 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>
Wed, 4 Jun 2025 12:38:04 +0000 (14:38 +0200)
commit164beeabcb1b383bf778cb4f7dd142236cacc779
tree2812bf7db7de1c6d75c23d3f6f1e40b566f0e993
parentd6fd1eee07675f293b2a40239ca2ec47c8798227
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