diff options
author | Alex Deucher <alexdeucher@gmail.com> | 2009-11-05 01:16:23 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2009-11-05 20:35:24 -0500 |
commit | 4170a6c1bc106d7fcf94f5842224ac4dac61006b (patch) | |
tree | d80e49a6ee44f11ee72df43debdba7b4aaa8bc3f /drivers | |
parent | ee59f2b462b0a7d2eb57ae59340d016589fa8e42 (diff) |
drm/radeon/kms/atom/dce3: fix up usPixelClock calculation for Transmitter tables
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_encoders.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_encoders.c b/drivers/gpu/drm/radeon/radeon_encoders.c index 2aa5994a29d5..355b0fbed927 100644 --- a/drivers/gpu/drm/radeon/radeon_encoders.c +++ b/drivers/gpu/drm/radeon/radeon_encoders.c | |||
@@ -725,10 +725,10 @@ atombios_dig_transmitter_setup(struct drm_encoder *encoder, int action) | |||
725 | 725 | ||
726 | if (ASIC_IS_DCE32(rdev)) { | 726 | if (ASIC_IS_DCE32(rdev)) { |
727 | if (radeon_encoder->pixel_clock > 165000) { | 727 | if (radeon_encoder->pixel_clock > 165000) { |
728 | args.v2.usPixelClock = cpu_to_le16((radeon_encoder->pixel_clock * 10 * 2) / 100); | 728 | args.v2.usPixelClock = cpu_to_le16((radeon_encoder->pixel_clock / 2) / 10); |
729 | args.v2.acConfig.fDualLinkConnector = 1; | 729 | args.v2.acConfig.fDualLinkConnector = 1; |
730 | } else { | 730 | } else { |
731 | args.v2.usPixelClock = cpu_to_le16((radeon_encoder->pixel_clock * 10 * 4) / 100); | 731 | args.v2.usPixelClock = cpu_to_le16(radeon_encoder->pixel_clock / 10); |
732 | } | 732 | } |
733 | if (dig->dig_block) | 733 | if (dig->dig_block) |
734 | args.v2.acConfig.ucEncoderSel = 1; | 734 | args.v2.acConfig.ucEncoderSel = 1; |
@@ -754,7 +754,10 @@ atombios_dig_transmitter_setup(struct drm_encoder *encoder, int action) | |||
754 | } | 754 | } |
755 | } else { | 755 | } else { |
756 | args.v1.ucConfig = ATOM_TRANSMITTER_CONFIG_CLKSRC_PPLL; | 756 | args.v1.ucConfig = ATOM_TRANSMITTER_CONFIG_CLKSRC_PPLL; |
757 | args.v1.usPixelClock = cpu_to_le16((radeon_encoder->pixel_clock) / 10); | 757 | if (radeon_encoder->pixel_clock > 165000) |
758 | args.v1.usPixelClock = cpu_to_le16((radeon_encoder->pixel_clock / 2) / 10); | ||
759 | else | ||
760 | args.v1.usPixelClock = cpu_to_le16(radeon_encoder->pixel_clock / 10); | ||
758 | 761 | ||
759 | switch (radeon_encoder->encoder_id) { | 762 | switch (radeon_encoder->encoder_id) { |
760 | case ENCODER_OBJECT_ID_INTERNAL_UNIPHY: | 763 | case ENCODER_OBJECT_ID_INTERNAL_UNIPHY: |