diff options
| author | Ken Chalmers <ken.chalmers@amd.com> | 2018-11-06 14:24:12 -0500 |
|---|---|---|
| committer | Alex Deucher <alexander.deucher@amd.com> | 2019-01-14 15:04:39 -0500 |
| commit | 380604e27bc9c26ce64a83044aa1ea76ffd28caf (patch) | |
| tree | 8e9a9e2cee34380c330bf9e497d0c208606c1a6d /drivers/gpu/drm/amd/display/dc/bios/command_table2.c | |
| parent | drm/amd/display: Minor code cleanup (diff) | |
| download | linux-380604e27bc9c26ce64a83044aa1ea76ffd28caf.tar.gz linux-380604e27bc9c26ce64a83044aa1ea76ffd28caf.zip | |
drm/amd/display: Use 100 Hz precision for pipe pixel clocks
[Why]
Users would like more accurate pixel clocks, especially for fractional
"TV" frame rates like 59.94 Hz.
[How]
Store and communicate pixel clocks with 100 Hz accuracy from
dc_crtc_timing through to BIOS command table setpixelclock call.
Signed-off-by: Ken Chalmers <ken.chalmers@amd.com>
Reviewed-by: Charlene Liu <Charlene.Liu@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/dc/bios/command_table2.c')
| -rw-r--r-- | drivers/gpu/drm/amd/display/dc/bios/command_table2.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/bios/command_table2.c b/drivers/gpu/drm/amd/display/dc/bios/command_table2.c index 2b5dc499a35e..7d3e57765eb2 100644 --- a/drivers/gpu/drm/amd/display/dc/bios/command_table2.c +++ b/drivers/gpu/drm/amd/display/dc/bios/command_table2.c @@ -301,9 +301,7 @@ static enum bp_result set_pixel_clock_v7( cmd_helper->encoder_mode_bp_to_atom( bp_params->signal_type, false); - /* We need to convert from KHz units into 10KHz units */ - clk.pixclk_100hz = cpu_to_le32(bp_params->target_pixel_clock * - 10); + clk.pixclk_100hz = cpu_to_le32(bp_params->target_pixel_clock_100hz); clk.deep_color_ratio = (uint8_t) bp->cmd_helper-> @@ -311,7 +309,7 @@ static enum bp_result set_pixel_clock_v7( bp_params->color_depth); DC_LOG_BIOS("%s:program display clock = %d"\ "colorDepth = %d\n", __func__,\ - bp_params->target_pixel_clock, bp_params->color_depth); + bp_params->target_pixel_clock_100hz, bp_params->color_depth); if (bp_params->flags.FORCE_PROGRAMMING_OF_PLL) clk.miscinfo |= PIXEL_CLOCK_V7_MISC_FORCE_PROG_PPLL; |
