All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915/gen9: Disable FBC on planes which have an unsupported config.
@ 2019-01-29 12:57 Gwan-gyeong Mun
  2019-01-29 13:16 ` ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Gwan-gyeong Mun @ 2019-01-29 12:57 UTC (permalink / raw)
  To: intel-gfx

Enabling FBC on a plane which has a combination of a 180-degree rotation
with having a Height that isn't divisible by 4 causes FIFO underrun,
so disable FBC on such a config.

Testcase: igt/kms_rotation_crc/multiplane-rotation-cropping-top
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105604

Signed-off-by: Gwan-gyeong Mun <gwan-gyeong.mun@intel.com>
---
 drivers/gpu/drm/i915/intel_fbc.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_fbc.c b/drivers/gpu/drm/i915/intel_fbc.c
index ccd5e110a19c..de4b5781922c 100644
--- a/drivers/gpu/drm/i915/intel_fbc.c
+++ b/drivers/gpu/drm/i915/intel_fbc.c
@@ -793,6 +793,18 @@ static bool intel_fbc_can_activate(struct intel_crtc *crtc)
 		return false;
 	}
 
+	/*
+	 * Work around a problem on GEN9 HW, where enabling FBC on a plane
+	 * which has a combination of a 180-degree rotation with having a Height
+	 * that isn't divisible by 4 causes FIFO underrun.
+	 */
+	if (IS_GEN(dev_priv, 9) &&
+	    (cache->plane.rotation == DRM_MODE_ROTATE_180) &&
+	    (fbc->state_cache.plane.src_h & 3)) {
+		fbc->no_fbc_reason = "plane has a combination of a 180-degree rotation with a misaligned Height";
+		return false;
+	}
+
 	return true;
 }
 
-- 
2.20.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-01-30 12:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-29 12:57 [PATCH] drm/i915/gen9: Disable FBC on planes which have an unsupported config Gwan-gyeong Mun
2019-01-29 13:16 ` ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
2019-01-29 13:34 ` ✓ Fi.CI.BAT: success " Patchwork
2019-01-29 16:42 ` ✓ Fi.CI.IGT: " Patchwork
2019-01-30 12:40 ` [PATCH] " Juha-Pekka Heikkila

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.