summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2010-02-09 21:56:39 -0600
committerEric Anholt <eric@anholt.net>2010-02-09 21:56:39 -0600
commit296979a972acd081d37b9f65a5679f081e81cb6e (patch)
tree34c50304b301c93e65db8b652708a5ff6d315b3e
parente767703244c9ecc3828886b87e903caa578bc78a (diff)
glamor: Align stride of fallback pixmap data to 32 bits.
fb/pixman demand this alignment, and all sorts of things go badly otherwise. Fixes piglit x11-8bpp-7x8-draw.
-rw-r--r--glamor/glamor.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/glamor/glamor.c b/glamor/glamor.c
index 7bb093474..7bc75aa13 100644
--- a/glamor/glamor.c
+++ b/glamor/glamor.c
@@ -112,7 +112,8 @@ glamor_create_pixmap(ScreenPtr screen, int w, int h, int depth,
0);
screen->ModifyPixmapHeader(pixmap, w, h, 0, 0,
- (w * pixmap->drawable.bitsPerPixel + 7) / 8,
+ (((w * pixmap->drawable.bitsPerPixel +
+ 7) / 8) + 3) & ~3,
NULL);
return pixmap;