Always setting the pixmap devPrivate.ptr to point at the new bits means not
having to check whether UXA is running or not as NoAccel requires the
pointer in all cases.

Signed-off-by: Keith Packard <kei...@keithp.com>
---
 src/i830_driver.c |    7 ++-----
 1 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/src/i830_driver.c b/src/i830_driver.c
index 067a098..72f091f 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -926,7 +926,6 @@ i830_xf86crtc_resize (ScrnInfoPtr scrn, int width, int 
height)
        i830_memory *new_front, *old_front;
        Bool        tiled;
        ScreenPtr   screen = screenInfo.screens[scrn->scrnIndex];
-       pointer     data = NULL;
 
        scrn->displayWidth = i830_pad_drawable_width(width, i830->cpp);
        tiled = i830_tiled_width(i830, &scrn->displayWidth, i830->cpp);
@@ -946,15 +945,13 @@ i830_xf86crtc_resize (ScrnInfoPtr scrn, int width, int 
height)
        i830_set_pixmap_bo(screen->GetScreenPixmap(screen),
                           new_front->bo);
        scrn->fbOffset = i830->front_buffer->offset;
-       if (!new_front->bo)
-           data = i830->FbBase + scrn->fbOffset;
        screen->ModifyPixmapHeader(screen->GetScreenPixmap(screen),
                                   width, height, -1, -1, scrn->displayWidth * 
i830->cpp,
-                                  data);
+                                  i830->FbBase + scrn->fbOffset);
        /* ick. xf86EnableDisableFBAccess smashes the screen pixmap devPrivate,
         * so update the value it uses
         */
-       scrn->pixmapPrivate.ptr = data;
+       scrn->pixmapPrivate.ptr = i830->FbBase + scrn->fbOffset;
        xf86DrvMsg(scrn->scrnIndex, X_INFO, "New front buffer at 0x%lx\n",
                   i830->front_buffer->offset);
        i830_set_new_crtc_bo(scrn);
-- 
1.6.3.3


------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
--
_______________________________________________
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to