FAILED: patch "[PATCH] drm/i915/gt: Poll aux invalidation register bit on" failed to apply to 6.1-stable tree
Subsystems (3)
[email protected]
maintainerThe patch below does not apply to the 6.1-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
To reproduce the conflict and resubmit, you may use the following commands:
git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.1.y
git checkout FETCH_HEAD
git cherry-pick -x 0fde2f23516a00fd90dfb980b66b4665fcbfa659
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2023080728-courier-quit-35fd@gregkh' --subject-prefix 'PATCH 6.1.y' HEAD^..
Possible dependencies:
0fde2f23516a ("drm/i915/gt: Poll aux invalidation register bit on invalidation") b2f59e902603 ("drm/i915: Add the gen12_needs_ccs_aux_inv helper")
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From 0fde2f23516a00fd90dfb980b66b4665fcbfa659 Mon Sep 17 00:00:00 2001
From: Jonathan Cavitt <[email protected]>
Date: Tue, 25 Jul 2023 02:19:49 +0200
Subject: [PATCH] drm/i915/gt: Poll aux invalidation register bit on
invalidation
For platforms that use Aux CCS, wait for aux invalidation to complete by checking the aux invalidation register bit is cleared.
drivers/gpu/drm/i915/gt/gen8_engine_cs.c +12 -5
@@ -184,7 +184,15 @@ u32 *gen12_emit_aux_table_inv(struct intel_gt *gt, u32 *cs, const i915_reg_t inv *cs++ =MI_LOAD_REGISTER_IMM (1 ) |MI_LRI_MMIO_REMAP_EN ; *cs++ =i915_mmio_reg_offset (inv_reg) + gsi_offset; *cs++ =AUX_INV ; - *cs++ =MI_NOOP ; + + *cs++ =MI_SEMAPHORE_WAIT_TOKEN | +MI_SEMAPHORE_REGISTER_POLL | +MI_SEMAPHORE_POLL | +MI_SEMAPHORE_SAD_EQ_SDD ; + *cs++ =0 ; + *cs++ =i915_mmio_reg_offset (inv_reg) + gsi_offset; + *cs++ =0 ; + *cs++ =0 ;return cs; }
@@ -292,10 +300,9 @@ int gen12_emit_flush_rcs(struct i915_request *rq, u32 mode)else if (engine->class ==COMPUTE_CLASS ) flags &= ~PIPE_CONTROL_3D_ENGINE_FLAGS ; + count =8 ;if (gen12_needs_ccs_aux_inv (rq->engine)) - count =8 +4 ; -else - count =8 ; + count +=8 ; cs =intel_ring_begin (rq, count);if (IS_ERR (cs))
@@ -338,7 +345,7 @@ int gen12_emit_flush_xcs(struct i915_request *rq, u32 mode) aux_inv = rq->engine->mask & ~GENMASK (_BCS (I915_MAX_BCS -1 ),BCS0 );if (aux_inv) - cmd +=4 ; + cmd +=8 ; } }
drivers/gpu/drm/i915/gt/intel_gpu_commands.h +1 -0
@@ -121,6 +121,7 @@#define MI_SEMAPHORE_TARGET (engine) ((engine)<<15)#define MI_SEMAPHORE_WAIT MI_INSTR(0x1c, 2)/* GEN8+ */ #define MI_SEMAPHORE_WAIT_TOKEN MI_INSTR(0x1c, 3)/* GEN12+ */ +#define MI_SEMAPHORE_REGISTER_POLL (1 << 16)#define MI_SEMAPHORE_POLL (1 << 15)#define MI_SEMAPHORE_SAD_GT_SDD (0 << 12)#define MI_SEMAPHORE_SAD_GTE_SDD (1 << 12)