i915: Disable Render Buffer compression for Gen11
This reverts commit 70cf2460d21d1a02501b8acda81e5c40dfdf78b6.
crrev/c/2944608 enabled RBC for Gen11, but we're still seeing instance
of garbage on the external display when device switch to dispaly mode
or lid open/close. So we disable RBC to fix the garbage issue.
BUG=b:197804801
TEST=signing in/out, fullscreening video, lid open/close, observe no artifacts
Change-Id: I1cde20c05e7127340ac68f7f70c39bb77b31e097
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/minigbm/+/3246443
Tested-by: Cooper Chiou <cooper.chiou@intel.com>
Reviewed-by: Dominik Behr <dbehr@chromium.org>
Commit-Queue: Miguel Casas-Sanchez <mcasas@chromium.org>
diff --git a/i915.c b/i915.c
index 055c582..6a44448 100644
--- a/i915.c
+++ b/i915.c
@@ -41,6 +41,9 @@
I915_FORMAT_MOD_Y_TILED, I915_FORMAT_MOD_X_TILED,
DRM_FORMAT_MOD_LINEAR };
+static const uint64_t gen11_modifier_order[] = { I915_FORMAT_MOD_Y_TILED, I915_FORMAT_MOD_X_TILED,
+ DRM_FORMAT_MOD_LINEAR };
+
struct modifier_support_t {
const uint64_t *order;
uint32_t count;
@@ -163,6 +166,10 @@
if (i915->gen == 12) {
i915->modifier.order = gen12_modifier_order;
i915->modifier.count = ARRAY_SIZE(gen12_modifier_order);
+ }
+ else if (i915->gen == 11) {
+ i915->modifier.order = gen11_modifier_order;
+ i915->modifier.count = ARRAY_SIZE(gen11_modifier_order);
} else {
i915->modifier.order = gen_modifier_order;
i915->modifier.count = ARRAY_SIZE(gen_modifier_order);