summaryrefslogtreecommitdiff
path: root/sys/dev/pci
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2023-10-20 03:41:57 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2023-10-20 03:41:57 +0000
commit6059f6e2a3489b0fd6ad5617b04179c80198b487 (patch)
tree66ad39fb82421ab667b64486cf8989dc9a5976c3 /sys/dev/pci
parent3054546bd4e10f3c06211dca9d399f87d3eebf83 (diff)
drm/i915: Don't set PIPE_CONTROL_FLUSH_L3 for aux inval
From Nirmoy Das f175665385fe9fdd996080806aa67e666475d3d8 in linux-6.1.y/6.1.59 128c20eda73bd3e78505c574fb17adb46195c98b in mainline linux
Diffstat (limited to 'sys/dev/pci')
-rw-r--r--sys/dev/pci/drm/i915/gt/gen8_engine_cs.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/sys/dev/pci/drm/i915/gt/gen8_engine_cs.c b/sys/dev/pci/drm/i915/gt/gen8_engine_cs.c
index cc846853687..efc22f9b17f 100644
--- a/sys/dev/pci/drm/i915/gt/gen8_engine_cs.c
+++ b/sys/dev/pci/drm/i915/gt/gen8_engine_cs.c
@@ -235,8 +235,17 @@ int gen12_emit_flush_rcs(struct i915_request *rq, u32 mode)
u32 flags = 0;
u32 *cs;
+ /*
+ * L3 fabric flush is needed for AUX CCS invalidation
+ * which happens as part of pipe-control so we can
+ * ignore PIPE_CONTROL_FLUSH_L3. Also PIPE_CONTROL_FLUSH_L3
+ * deals with Protected Memory which is not needed for
+ * AUX CCS invalidation and lead to unwanted side effects.
+ */
+ if (mode & EMIT_FLUSH)
+ flags |= PIPE_CONTROL_FLUSH_L3;
+
flags |= PIPE_CONTROL_TILE_CACHE_FLUSH;
- flags |= PIPE_CONTROL_FLUSH_L3;
flags |= PIPE_CONTROL_RENDER_TARGET_CACHE_FLUSH;
flags |= PIPE_CONTROL_DEPTH_CACHE_FLUSH;
/* Wa_1409600907:tgl,adl-p */