From 33a317f48eb3fe888177235ee49b635fbb8cda2f Mon Sep 17 00:00:00 2001 From: marha Date: Mon, 4 Jan 2010 15:34:07 +0000 Subject: Git update 4/1/2010 --- xorg-server/exa/exa_accel.c | 46 ++++++++++++--------------------------------- 1 file changed, 12 insertions(+), 34 deletions(-) (limited to 'xorg-server/exa/exa_accel.c') diff --git a/xorg-server/exa/exa_accel.c b/xorg-server/exa/exa_accel.c index 0f6e5f78a..4c55a4c54 100644 --- a/xorg-server/exa/exa_accel.c +++ b/xorg-server/exa/exa_accel.c @@ -157,6 +157,10 @@ exaDoPutImage (DrawablePtr pDrawable, GCPtr pGC, int depth, int x, int y, if (pExaScr->fallback_counter || pExaPixmap->accel_blocked || !pExaScr->info->UploadToScreen) return FALSE; + /* If there's a system copy, we want to save the result there */ + if (pExaPixmap->pDamage) + return FALSE; + /* Don't bother with under 8bpp, XYPixmaps. */ if (format != ZPixmap || bpp < 8) return FALSE; @@ -168,17 +172,6 @@ exaDoPutImage (DrawablePtr pDrawable, GCPtr pGC, int depth, int x, int y, if (pExaScr->swappedOut) return FALSE; - if (pExaScr->do_migration) { - ExaMigrationRec pixmaps[1]; - - pixmaps[0].as_dst = TRUE; - pixmaps[0].as_src = FALSE; - pixmaps[0].pPix = pPix; - pixmaps[0].pReg = DamagePendingRegion(pExaPixmap->pDamage); - - exaDoMigration (pixmaps, 1, TRUE); - } - pPix = exaGetOffscreenPixmap (pDrawable, &xoff, &yoff); if (!pPix) @@ -1043,6 +1036,7 @@ exaFillRegionSolid (DrawablePtr pDrawable, RegionPtr pRegion, Pixel pixel, pDrawable->width == 1 && pDrawable->height == 1 && pDrawable->bitsPerPixel != 24) { ExaPixmapPriv(pPixmap); + RegionPtr pending_damage = DamagePendingRegion(pExaPixmap->pDamage); switch (pDrawable->bitsPerPixel) { case 32: @@ -1057,6 +1051,9 @@ exaFillRegionSolid (DrawablePtr pDrawable, RegionPtr pRegion, Pixel pixel, REGION_UNION(pScreen, &pExaPixmap->validSys, &pExaPixmap->validSys, pRegion); + REGION_UNION(pScreen, &pExaPixmap->validFB, &pExaPixmap->validFB, + pRegion); + REGION_SUBTRACT(pScreen, pending_damage, pending_damage, pRegion); } ret = TRUE; @@ -1257,35 +1254,16 @@ exaGetImage (DrawablePtr pDrawable, int x, int y, int w, int h, { ExaScreenPriv (pDrawable->pScreen); PixmapPtr pPix = exaGetDrawablePixmap (pDrawable); + ExaPixmapPriv(pPix); int xoff, yoff; Bool ok; if (pExaScr->fallback_counter || pExaScr->swappedOut) goto fallback; - exaGetDrawableDeltas (pDrawable, pPix, &xoff, &yoff); - - if (pExaScr->do_migration) { - BoxRec Box; - RegionRec Reg; - ExaMigrationRec pixmaps[1]; - - Box.x1 = pDrawable->y + x + xoff; - Box.y1 = pDrawable->y + y + yoff; - Box.x2 = Box.x1 + w; - Box.y2 = Box.y1 + h; - - REGION_INIT(pScreen, &Reg, &Box, 1); - - pixmaps[0].as_dst = FALSE; - pixmaps[0].as_src = TRUE; - pixmaps[0].pPix = pPix; - pixmaps[0].pReg = &Reg; - - exaDoMigration(pixmaps, 1, FALSE); - - REGION_UNINIT(pScreen, &Reg); - } + /* If there's a system copy, we want to save the result there */ + if (pExaPixmap->pDamage) + goto fallback; pPix = exaGetOffscreenPixmap (pDrawable, &xoff, &yoff); -- cgit v1.2.3 From 163827567b71b0763a4c1a7104159cd08b5c2d95 Mon Sep 17 00:00:00 2001 From: marha Date: Tue, 5 Jan 2010 08:37:48 +0000 Subject: Git update 5/1/2010 --- xorg-server/dix/devices.c | 6 +++--- xorg-server/exa/exa_accel.c | 11 +++++++++++ 2 files changed, 14 insertions(+), 3 deletions(-) (limited to 'xorg-server/exa/exa_accel.c') diff --git a/xorg-server/dix/devices.c b/xorg-server/dix/devices.c index 6329d2810..92b95ed69 100644 --- a/xorg-server/dix/devices.c +++ b/xorg-server/dix/devices.c @@ -842,6 +842,9 @@ CloseDevice(DeviceIntPtr dev) if(dev->valuator && dev->valuator->accelScheme.AccelCleanupProc) dev->valuator->accelScheme.AccelCleanupProc(dev); + while (dev->xkb_interest) + XkbRemoveResourceClient((DevicePtr)dev,dev->xkb_interest->resource); + xfree(dev->name); classes = (ClassesPtr)&dev->key; @@ -853,9 +856,6 @@ CloseDevice(DeviceIntPtr dev) FreeAllDeviceClasses(classes); } - while (dev->xkb_interest) - XkbRemoveResourceClient((DevicePtr)dev,dev->xkb_interest->resource); - if (DevHasCursor(dev) && dev->spriteInfo->sprite) { xfree(dev->spriteInfo->sprite->spriteTrace); xfree(dev->spriteInfo->sprite); diff --git a/xorg-server/exa/exa_accel.c b/xorg-server/exa/exa_accel.c index 4c55a4c54..4680c3709 100644 --- a/xorg-server/exa/exa_accel.c +++ b/xorg-server/exa/exa_accel.c @@ -172,6 +172,17 @@ exaDoPutImage (DrawablePtr pDrawable, GCPtr pGC, int depth, int x, int y, if (pExaScr->swappedOut) return FALSE; + if (pExaScr->do_migration) { + ExaMigrationRec pixmaps[1]; + + pixmaps[0].as_dst = TRUE; + pixmaps[0].as_src = FALSE; + pixmaps[0].pPix = pPix; + pixmaps[0].pReg = DamagePendingRegion(pExaPixmap->pDamage); + + exaDoMigration (pixmaps, 1, TRUE); + } + pPix = exaGetOffscreenPixmap (pDrawable, &xoff, &yoff); if (!pPix) -- cgit v1.2.3