Patch "drm/amd/display: Fix pixel clock programming" has been added to the 5.4-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    drm/amd/display: Fix pixel clock programming

to the 5.4-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     drm-amd-display-fix-pixel-clock-programming.patch
and it can be found in the queue-5.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 262513aa5386b304dedb17c265197c770e9b9b32
Author: Ilya Bakoulin <Ilya.Bakoulin@xxxxxxx>
Date:   Tue Jul 26 16:19:38 2022 -0400

    drm/amd/display: Fix pixel clock programming
    
    [ Upstream commit 04fb918bf421b299feaee1006e82921d7d381f18 ]
    
    [Why]
    Some pixel clock values could cause HDMI TMDS SSCPs to be misaligned
    between different HDMI lanes when using YCbCr420 10-bit pixel format.
    
    BIOS functions for transmitter/encoder control take pixel clock in kHz
    increments, whereas the function for setting the pixel clock is in 100Hz
    increments. Setting pixel clock to a value that is not on a kHz boundary
    will cause the issue.
    
    [How]
    Round pixel clock down to nearest kHz in 10/12-bpc cases.
    
    Reviewed-by: Aric Cyr <Aric.Cyr@xxxxxxx>
    Acked-by: Brian Chang <Brian.Chang@xxxxxxx>
    Signed-off-by: Ilya Bakoulin <Ilya.Bakoulin@xxxxxxx>
    Tested-by: Daniel Wheeler <daniel.wheeler@xxxxxxx>
    Signed-off-by: Alex Deucher <alexander.deucher@xxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c b/drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c
index eca67d5d5b10d..721be82ccebec 100644
--- a/drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c
+++ b/drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c
@@ -546,9 +546,11 @@ static void dce112_get_pix_clk_dividers_helper (
 		switch (pix_clk_params->color_depth) {
 		case COLOR_DEPTH_101010:
 			actual_pixel_clock_100hz = (actual_pixel_clock_100hz * 5) >> 2;
+			actual_pixel_clock_100hz -= actual_pixel_clock_100hz % 10;
 			break;
 		case COLOR_DEPTH_121212:
 			actual_pixel_clock_100hz = (actual_pixel_clock_100hz * 6) >> 2;
+			actual_pixel_clock_100hz -= actual_pixel_clock_100hz % 10;
 			break;
 		case COLOR_DEPTH_161616:
 			actual_pixel_clock_100hz = actual_pixel_clock_100hz * 2;



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux