summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2009-11-30 16:52:10 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2009-11-30 16:56:48 +0000
commit6729b508c44bfca0b0dbef238a8732adbed6d4c9 (patch)
tree29d91e4d943380e2cd2d7d3ddf7907dc27c7a92a
parent85fe41126e83b35954dc2066eb103e0555e207a4 (diff)
uxa: Initialise lists for private pixmap structure.
When updating a buffer object for the framebuffer, we may need to allocate a fresh pixmap private structure, for example if the pixmap is replaced due to resize. When doing so it is then imperative to initialise the circularly linked lists correctly. Should fix the fault: #0 i830_set_pixmap_bo (pixmap=0x24ab380, bo=0x24ab780) at i830_uxa.c:524 #1 0x00007f8615c629fd in drmmode_xf86crtc_resize (scrn=0x247a320, width=1280, height=800) at drmmode_display.c:1345 #2 0x000000000051246c in xf86RandR12ScreenSetSize (pScreen=0x24824f0, width=<value optimized out>, height=<value optimized out>, mmWidth=<value optimized out>, mmHeight=<value optimized out>) at xf86RandR12.c:709 #3 0x0000000000512aa8 in xf86RandR12CreateScreenResources (pScreen=<value optimized out>) at xf86RandR12.c:839 #4 0x0000000000514ec0 in xf86CrtcCreateScreenResources (screen=0x24824f0) at xf86Crtc.c:727 #5 0x0000000000424fb3 in main (argc=<value optimized out>, argv=<value optimized out>, envp=<value optimized out>) at main.c:215 as reported by 'buscher'. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r--src/i830_uxa.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/i830_uxa.c b/src/i830_uxa.c
index d53af043..89da5d00 100644
--- a/src/i830_uxa.c
+++ b/src/i830_uxa.c
@@ -530,6 +530,9 @@ void i830_set_pixmap_bo(PixmapPtr pixmap, dri_bo * bo)
priv = xcalloc(1, sizeof (struct intel_pixmap));
if (priv == NULL)
goto BAIL;
+
+ list_init(&priv->batch);
+ list_init(&priv->flush);
}
dri_bo_reference(bo);