aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
authorAlex Deucher <alexdeucher@gmail.com>2011-05-25 01:00:45 -0400
committerDave Airlie <airlied@redhat.com>2011-05-25 15:10:48 +1000
commitac10f81d94f49f1bd9618680263400d275ddf825 (patch)
tree2efa9488ac93523560bf988dec8eaedad29f9b44 /drivers/gpu
parent2ec8a5feaf3000bf4f9744d0caad0d5f12ce1409 (diff)
downloadkernel_samsung_smdk4412-ac10f81d94f49f1bd9618680263400d275ddf825.zip
kernel_samsung_smdk4412-ac10f81d94f49f1bd9618680263400d275ddf825.tar.gz
kernel_samsung_smdk4412-ac10f81d94f49f1bd9618680263400d275ddf825.tar.bz2
drm/radeon/kms/blit: workaround some hw issues on evergreen+
Signed-off-by: Alex Deucher <alexdeucher@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/radeon/evergreen_blit_kms.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/evergreen_blit_kms.c b/drivers/gpu/drm/radeon/evergreen_blit_kms.c
index ba06a69..4086729 100644
--- a/drivers/gpu/drm/radeon/evergreen_blit_kms.c
+++ b/drivers/gpu/drm/radeon/evergreen_blit_kms.c
@@ -199,6 +199,16 @@ static void
set_scissors(struct radeon_device *rdev, int x1, int y1,
int x2, int y2)
{
+ /* workaround some hw bugs */
+ if (x2 == 0)
+ x1 = 1;
+ if (y2 == 0)
+ y1 = 1;
+ if (rdev->family == CHIP_CAYMAN) {
+ if ((x2 == 1) && (y2 == 1))
+ x2 = 2;
+ }
+
radeon_ring_write(rdev, PACKET3(PACKET3_SET_CONTEXT_REG, 2));
radeon_ring_write(rdev, (PA_SC_SCREEN_SCISSOR_TL - PACKET3_SET_CONTEXT_REG_START) >> 2);
radeon_ring_write(rdev, (x1 << 0) | (y1 << 16));