Skip to content

Commit b7a855f

Browse files
sberbzAndi Shyti
authored andcommitted
drm/i915/gt: Relocate Gen6 context-specific workaround
CACHE_MODE_0 register should be saved and restored as part of the context, not during engine reset. Move the related workaround (RC_OP_FLUSH_ENABLE) from rcs_engine_wa_init() to gen6_ctx_workarounds_init() for Gen6 platforms. This ensures the WA is applied during context initialisation. CM0_STC_EVICT_DISABLE_LRA_SNB is also Gen6-specific, but it does not stick when applied in context, so it remains in engine init. BSPEC: 11322 Signed-off-by: Sebastian Brzezinka <[email protected]> Reviewed-by: Andi Shyti <[email protected]> Reviewed-by: Krzysztof Karas <[email protected]> Signed-off-by: Andi Shyti <[email protected]> Link: https://lore.kernel.org/r/f493bab389e51b2faf7c9a439724e9ea9ca04053.1754902406.git.sebastian.brzezinka@intel.com
1 parent 77a1645 commit b7a855f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/gpu/drm/i915/gt/intel_workarounds.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -337,6 +337,9 @@ static void gen6_ctx_workarounds_init(struct intel_engine_cs *engine,
337337
struct i915_wa_list *wal)
338338
{
339339
wa_masked_en(wal, INSTPM, INSTPM_FORCE_ORDERING);
340+
341+
/* WaDisable_RenderCache_OperationalFlush:snb */
342+
wa_masked_dis(wal, CACHE_MODE_0, RC_OP_FLUSH_ENABLE);
340343
}
341344

342345
static void gen7_ctx_workarounds_init(struct intel_engine_cs *engine,
@@ -2644,9 +2647,6 @@ rcs_engine_wa_init(struct intel_engine_cs *engine, struct i915_wa_list *wal)
26442647
GEN6_WIZ_HASHING_MASK,
26452648
GEN6_WIZ_HASHING_16x4);
26462649

2647-
/* WaDisable_RenderCache_OperationalFlush:snb */
2648-
wa_masked_dis(wal, CACHE_MODE_0, RC_OP_FLUSH_ENABLE);
2649-
26502650
/*
26512651
* From the Sandybridge PRM, volume 1 part 3, page 24:
26522652
* "If this bit is set, STCunit will have LRA as replacement

0 commit comments

Comments
 (0)