]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm/amd/display: Add a left edge pixel if in YCbCr422 or YCbCr420 and odm
authorPeterson Guo <peterson.guo@amd.com>
Fri, 8 Nov 2024 00:20:02 +0000 (19:20 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 14 Dec 2024 19:03:29 +0000 (20:03 +0100)
commit2e7bea50a9b78f66267eb7c4e0d11c6aaf3406a6
tree431a074b4ef6288488ea9bec99c596446ae56f49
parentf443172fbf9fde26b28e05f1e08134edaa3217f4
drm/amd/display: Add a left edge pixel if in YCbCr422 or YCbCr420 and odm

commit 63e7ee677c74e981257cedfdd8543510d09096ba upstream.

[WHY]
On some cards when odm is used, the monitor will have 2 separate pipes
split vertically. When compression is used on the YCbCr colour space on
the second pipe to have correct colours, we need to read a pixel from the
end of first pipe to accurately display colours. Hardware was programmed
properly to account for this extra pixel but it was not calculated
properly in software causing a split screen on some monitors.

[HOW]
The fix adjusts the second pipe's viewport and timings if the pixel
encoding is YCbCr422 or YCbCr420.

Cc: Mario Limonciello <mario.limonciello@amd.com>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Reviewed-by: George Shen <george.shen@amd.com>
Signed-off-by: Peterson Guo <peterson.guo@amd.com>
Signed-off-by: Alex Hung <alex.hung@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/amd/display/dc/resource/dcn20/dcn20_resource.c