[Intel-gfx] [PATCH] drm/i915/fbc: disable FBC on Nightfury board

Lee Shawn C shawn.c.lee at intel.com
Thu Aug 27 05:51:29 UTC 2020


Customer report random display flicker issue on Nightfury board.
And we found this problem might be caused by VT-d and FBC are
both enabled. According to sighting report, it recommend to turn
drm/i915/fbc: disable FBC on Nightfury board

Customer report random display flicker issue on Nightfury board.
And we found this problem might be caused by VT-d and FBC are
both enabled. According to sighting report, it recommend to turn
FBC off to workaround this kind of issue.

This change refer to DMI BOARD_VENDOR and BOARD_NAME information
to disable FBC.

Cc: Ville Syrjälä <ville.syrjala at linux.intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi at intel.com>
Cc: Mika Kuoppala <mika.kuoppala at linux.intel.com>
Cc: Jani Nikula <jani.nikula at intel.com>
Cc: William Tseng <william.tseng at intel.com>
Cc: Cooper Chiou <cooper.chiou at intel.com>
Signed-off-by: Lee Shawn C <shawn.c.lee at intel.com>
---
 drivers/gpu/drm/i915/display/intel_fbc.c | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

diff --git a/drivers/gpu/drm/i915/display/intel_fbc.c b/drivers/gpu/drm/i915/display/intel_fbc.c
index 327af428d73f..20660fdbab36 100644
--- a/drivers/gpu/drm/i915/display/intel_fbc.c
+++ b/drivers/gpu/drm/i915/display/intel_fbc.c
@@ -39,6 +39,7 @@
  */
 
 #include <drm/drm_fourcc.h>
+#include <linux/dmi.h>
 
 #include "i915_drv.h"
 #include "i915_trace.h"
@@ -1439,6 +1440,24 @@ static int intel_sanitize_fbc_option(struct drm_i915_private *dev_priv)
 	return 0;
 }
 
+static int intel_fbc_vtd_callback(const struct dmi_system_id *id)
+{
+	DRM_DEBUG_KMS("Disabling FBC to prevent screen flicker on %s device\n", id->ident);
+	return 1;
+}
+
+static const struct dmi_system_id intel_fbc_vtd_detect[] = {
+	{
+		.callback = intel_fbc_vtd_callback,
+		.ident = "Google Nightfury",
+		.matches = {
+			DMI_MATCH(DMI_BOARD_VENDOR, "Google"),
+			DMI_MATCH(DMI_BOARD_NAME, "Nightfury"),
+		},
+	},
+	{ }
+};
+
 static bool need_fbc_vtd_wa(struct drm_i915_private *dev_priv)
 {
 	/* WaFbcTurnOffFbcWhenHyperVisorIsUsed:skl,bxt */
@@ -1450,6 +1469,9 @@ static bool need_fbc_vtd_wa(struct drm_i915_private *dev_priv)
 		return true;
 	}
 
+	if (dmi_check_system(intel_fbc_vtd_detect))
+		return true;
+
 	return false;
 }
 
-- 
2.17.1



More information about the Intel-gfx mailing list