summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2011-10-27 18:07:53 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2011-10-27 18:06:34 +0100
commit14a065a267523f9a31be07daaab19b67e9f02290 (patch)
treed33e6df2a58ef3a3ea32bbffdb0e62db66269dec
parent5d52d5009375618bb703909fa0fad04e6d54a2ba (diff)
sna: Create scratch pixmap on the CPU
Contrary to earlier belief, the only usage of CREATE_PIXMAP_USAGE_SCRATCH in the dix/mi are either along paths unused by us or more importantly for operations which are detrimental to create GPU-only buffers. So create CPU pixmaps instead. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r--src/sna/sna_accel.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index c0f95725..f3a9251f 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -265,11 +265,8 @@ static PixmapPtr sna_create_pixmap(ScreenPtr screen,
DBG(("%s(%d, %d, %d, usage=%x)\n", __FUNCTION__,
width, height, depth, usage));
- if (usage == CREATE_PIXMAP_USAGE_SCRATCH &&
- to_sna_from_screen(screen)->have_render)
- return sna_pixmap_create_scratch(screen,
- width, height, depth,
- I915_TILING_Y);
+ if (usage == CREATE_PIXMAP_USAGE_SCRATCH)
+ return fbCreatePixmap(screen, width, height, depth, usage);
if (FORCE_GPU_ONLY && width && height)
return sna_pixmap_create_scratch(screen,