diff options
author | Jonathan Cavitt <[email protected]> | 2023-07-25 02:19:46 +0200 |
---|---|---|
committer | Tvrtko Ursulin <[email protected]> | 2023-08-01 10:49:27 +0100 |
commit | 78a6ccd65fa3a7cc697810db079cc4b84dff03d5 (patch) | |
tree | 78c616ca1e238d011c9dfa44825252ae40c491f6 | |
parent | b2f59e9026038a5bbcbc0019fa58f963138211ee (diff) |
drm/i915/gt: Ensure memory quiesced before invalidation
All memory traffic must be quiesced before requesting
an aux invalidation on platforms that use Aux CCS.
Fixes: 972282c4cf24 ("drm/i915/gen12: Add aux table invalidate for all engines")
Requires: a2a4aa0eef3b ("drm/i915: Add the gen12_needs_ccs_aux_inv helper")
Signed-off-by: Jonathan Cavitt <[email protected]>
Signed-off-by: Andi Shyti <[email protected]>
Cc: <[email protected]> # v5.8+
Reviewed-by: Nirmoy Das <[email protected]>
Reviewed-by: Andrzej Hajda <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
(cherry picked from commit ad8ebf12217e451cd19804b1c3e97ad56491c74a)
Signed-off-by: Tvrtko Ursulin <[email protected]>
-rw-r--r-- | drivers/gpu/drm/i915/gt/gen8_engine_cs.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/gt/gen8_engine_cs.c b/drivers/gpu/drm/i915/gt/gen8_engine_cs.c index 460c9225a50f..6210b38a2d38 100644 --- a/drivers/gpu/drm/i915/gt/gen8_engine_cs.c +++ b/drivers/gpu/drm/i915/gt/gen8_engine_cs.c @@ -214,7 +214,11 @@ int gen12_emit_flush_rcs(struct i915_request *rq, u32 mode) { struct intel_engine_cs *engine = rq->engine; - if (mode & EMIT_FLUSH) { + /* + * On Aux CCS platforms the invalidation of the Aux + * table requires quiescing memory traffic beforehand + */ + if (mode & EMIT_FLUSH || gen12_needs_ccs_aux_inv(engine)) { u32 flags = 0; int err; u32 *cs; |