aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/drm/radeon_state.c
diff options
context:
space:
mode:
authorchaohong guo <Minskey.Guo@Sun.COM>2007-10-14 20:45:49 -0400
committerDave Airlie <airlied@redhat.com>2007-10-14 20:45:49 -0400
commiteed0f722b3fccb1eb2706b5f484cb511d46f70b8 (patch)
tree70c3fb4bb784dfb1c8cb0253ea95672d1b540c91 /drivers/char/drm/radeon_state.c
parent54583bf4efda79388fc13163e35c016c8bc5de81 (diff)
radeon: Commit the ring after each partial texture upload blit.
This makes sure each blit starts as early as possible, which may improve texture upload performance in some cases. Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/char/drm/radeon_state.c')
-rw-r--r--drivers/char/drm/radeon_state.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/char/drm/radeon_state.c b/drivers/char/drm/radeon_state.c
index ada820717ade..69c9f2febf43 100644
--- a/drivers/char/drm/radeon_state.c
+++ b/drivers/char/drm/radeon_state.c
@@ -1861,6 +1861,7 @@ static int radeon_cp_dispatch_texture(struct drm_device * dev,
1861 OUT_RING((image->width << 16) | height); 1861 OUT_RING((image->width << 16) | height);
1862 RADEON_WAIT_UNTIL_2D_IDLE(); 1862 RADEON_WAIT_UNTIL_2D_IDLE();
1863 ADVANCE_RING(); 1863 ADVANCE_RING();
1864 COMMIT_RING();
1864 1865
1865 radeon_cp_discard_buffer(dev, buf); 1866 radeon_cp_discard_buffer(dev, buf);
1866 1867
@@ -1878,6 +1879,8 @@ static int radeon_cp_dispatch_texture(struct drm_device * dev,
1878 RADEON_FLUSH_CACHE(); 1879 RADEON_FLUSH_CACHE();
1879 RADEON_WAIT_UNTIL_2D_IDLE(); 1880 RADEON_WAIT_UNTIL_2D_IDLE();
1880 ADVANCE_RING(); 1881 ADVANCE_RING();
1882 COMMIT_RING();
1883
1881 return 0; 1884 return 0;
1882} 1885}
1883 1886
@@ -2378,7 +2381,6 @@ static int radeon_cp_texture(struct drm_device *dev, void *data, struct drm_file
2378 2381
2379 ret = radeon_cp_dispatch_texture(dev, file_priv, tex, &image); 2382 ret = radeon_cp_dispatch_texture(dev, file_priv, tex, &image);
2380 2383
2381 COMMIT_RING();
2382 return ret; 2384 return ret;
2383} 2385}
2384 2386