xf86-video-intel: 3 commits - src/sna/sna_accel.c src/sna/sna_display.c

Chris Wilson ickle at kemper.freedesktop.org
Wed Sep 3 02:26:08 PDT 2014


 src/sna/sna_accel.c   |    9 +++++----
 src/sna/sna_display.c |    7 +++++++
 2 files changed, 12 insertions(+), 4 deletions(-)

New commits:
commit aa10f480c566b8523cdd49b3e23f64b7b9625987
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Wed Sep 3 10:24:19 2014 +0100

    sna: Drop false IGNORE_DAMAGE hint
    
    IGNORE_DAMAGE is used by sna_drawable_use_bo to ignore both CPU/GPU
    damage. It used to only ignore CPU damage, but now is a more general
    hint. However, here we were intending to only say ignore the cpu damage
    that we explicitly discarded anyway.
    
    References: https://bugs.freedesktop.org/show_bug.cgi?id=81973
    Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>

diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index a2d77ad..7df522b 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -6307,10 +6307,8 @@ discard_cow:
 				hint |= IGNORE_DAMAGE;
 			if (dst_priv->cpu_damage &&
 			    region_subsumes_damage(region,
-						   dst_priv->cpu_damage)) {
+						   dst_priv->cpu_damage))
 				discard_cpu_damage(sna, dst_priv);
-				hint |= IGNORE_DAMAGE;
-			}
 		}
 		bo = sna_drawable_use_bo(&dst_pixmap->drawable, hint,
 					 &region->extents, &damage);
commit 51e364ded28e9a8e02a380c041a2c5784381df35
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Wed Sep 3 10:23:18 2014 +0100

    sna: Trace move-to-gpu overrides with extra DBG
    
    Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>

diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index 52c5a90..a2d77ad 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -2682,6 +2682,7 @@ sna_drawable_move_region_to_cpu(DrawablePtr drawable,
 	}
 
 	if (priv->move_to_gpu) {
+		DBG(("%s: applying move-to-gpu override\n", __FUNCTION__));
 		if ((flags & MOVE_READ) == 0)
 			sna_pixmap_discard_shadow_damage(priv, region);
 		if (!priv->move_to_gpu(sna, priv, MOVE_READ)) {
@@ -3240,6 +3241,7 @@ sna_pixmap_move_area_to_gpu(PixmapPtr pixmap, const BoxRec *box, unsigned int fl
 	if (priv->move_to_gpu) {
 		unsigned int hint;
 
+		DBG(("%s: applying move-to-gpu override\n", __FUNCTION__));
 		hint = flags | MOVE_READ;
 		if ((flags & MOVE_READ) == 0) {
 			RegionRec region;
@@ -3778,6 +3780,7 @@ use_gpu_bo:
 
 		sna = to_sna_from_pixmap(pixmap);
 
+		DBG(("%s: applying move-to-gpu override\n", __FUNCTION__));
 		if (flags & IGNORE_DAMAGE) {
 			region.extents = *box;
 			region.data = NULL;
@@ -6228,7 +6231,7 @@ sna_copy_boxes(DrawablePtr src, DrawablePtr dst, GCPtr gc,
 					   region, dx, dy,
 					   bitplane, closure);
 
-	DBG(("%s (boxes=%dx[(%d, %d), (%d, %d)...], src pixmap=%ld+(%d, %d), dst pixmap=%ld=+(%d, %d), alu=%d, src.size=%dx%d, dst.size=%dx%d)\n",
+	DBG(("%s (boxes=%dx[(%d, %d), (%d, %d)...], src pixmap=%ld+(%d, %d), dst pixmap=%ld+(%d, %d), alu=%d, src.size=%dx%d, dst.size=%dx%d)\n",
 	     __FUNCTION__, n,
 	     box[0].x1, box[0].y1, box[0].x2, box[0].y2,
 	     src_pixmap->drawable.serialNumber, dx, dy,
commit ee7ed478a2bb81c923d29106b0b1dfd73161c2fc
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Wed Sep 3 08:20:03 2014 +0100

    sna: Skip over hotunplugged outputs during CRTC set
    
    These outputs are already marked as disconnected and so should be
    excluded from the CRTC set, but to be safe skip over them.
    
    Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>

diff --git a/src/sna/sna_display.c b/src/sna/sna_display.c
index a1a8782..c972e31 100644
--- a/src/sna/sna_display.c
+++ b/src/sna/sna_display.c
@@ -981,6 +981,13 @@ sna_crtc_apply(xf86CrtcPtr crtc)
 		if (output->crtc != crtc)
 			continue;
 
+		/* Skip over any hotunplugged outputs so that we can
+		 * recover in cases where the previous mode is now
+		 * only partially valid.
+		 */
+		if (!to_sna_output(output)->id)
+			continue;
+
 		DBG(("%s: attaching output '%s' %d [%d] to crtc:%d (pipe %d) (possible crtc:%x, possible clones:%x)\n",
 		     __FUNCTION__, output->name, i, to_connector_id(output),
 		     sna_crtc->id, sna_crtc->pipe,


More information about the xorg-commit mailing list