FAILED: patch "[PATCH] drm/i915/gt: Enable the CCS_FLUSH bit in the pipe control and" 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 824df77ab2107d8d4740b834b276681a41ae1ac8
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2023080745-flashback-clavicle-561f@gregkh' --subject-prefix 'PATCH 6.1.y' HEAD^..
Possible dependencies:
824df77ab210 ("drm/i915/gt: Enable the CCS_FLUSH bit in the pipe control and in the CS") 592b228f12e1 ("drm/i915/gt: Rename flags with bit_group_X according to the datasheet") 78a6ccd65fa3 ("drm/i915/gt: Ensure memory quiesced before invalidation") d922b80b1010 ("drm/i915/gt: Add workaround 14016712196")
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From 824df77ab2107d8d4740b834b276681a41ae1ac8 Mon Sep 17 00:00:00 2001
From: Andi Shyti <[email protected]>
Date: Tue, 25 Jul 2023 02:19:48 +0200
Subject: [PATCH] drm/i915/gt: Enable the CCS_FLUSH bit in the pipe control and
in the CS
Enable the CCS_FLUSH bit 13 in the control pipe for render and compute engines in platforms starting from Meteor Lake (BSPEC 43904 and 47112).
For the copy engine add MI_FLUSH_DW_CCS (bit 16) in the command streamer.
Requires: 8da173db894a ("drm/i915/gt: Rename flags with bit_group_X according to the datasheet")
drivers/gpu/drm/i915/gt/gen8_engine_cs.c +11 -0
@@ -230,6 +230,13 @@ int gen12_emit_flush_rcs(struct i915_request *rq, u32 mode) bit_group_0 |=PIPE_CONTROL0_HDC_PIPELINE_FLUSH ; +/* +* When required, in MTL and beyond platforms we +* need to set the CCS_FLUSH bit in the pipe control +*/ +if (GRAPHICS_VER_FULL (rq->i915) >=IP_VER (12 ,70 )) + bit_group_0 |=PIPE_CONTROL_CCS_FLUSH ; + bit_group_1 |=PIPE_CONTROL_TILE_CACHE_FLUSH ; bit_group_1 |=PIPE_CONTROL_FLUSH_L3 ; bit_group_1 |=PIPE_CONTROL_RENDER_TARGET_CACHE_FLUSH ;
@@ -356,6 +363,10 @@ int gen12_emit_flush_xcs(struct i915_request *rq, u32 mode) cmd |=MI_INVALIDATE_TLB ;if (rq->engine->class ==VIDEO_DECODE_CLASS ) cmd |=MI_INVALIDATE_BSD ; + +if (gen12_needs_ccs_aux_inv (rq->engine) && + rq->engine->class ==COPY_ENGINE_CLASS ) + cmd |=MI_FLUSH_DW_CCS ; } *cs++ = cmd;
drivers/gpu/drm/i915/gt/intel_gpu_commands.h +1 -0
@@ -299,6 +299,7 @@#define PIPE_CONTROL_QW_WRITE (1<<14)#define PIPE_CONTROL_POST_SYNC_OP_MASK (3<<14)#define PIPE_CONTROL_DEPTH_STALL (1<<13) +#define PIPE_CONTROL_CCS_FLUSH (1<<13)/* MTL+ */ #define PIPE_CONTROL_WRITE_FLUSH (1<<12)#define PIPE_CONTROL_RENDER_TARGET_CACHE_FLUSH (1<<12)/* gen6+ */ #define PIPE_CONTROL_INSTRUCTION_CACHE_INVALIDATE (1<<11)/* MBZ on ILK */