All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] TLB invalidation cleanup
@ 2022-12-19 10:13 ` Tvrtko Ursulin
  0 siblings, 0 replies; 23+ messages in thread
From: Tvrtko Ursulin @ 2022-12-19 10:13 UTC (permalink / raw)
  To: Intel-gfx, dri-devel; +Cc: Tvrtko Ursulin

From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>

First patch to make the platform check not catch all due current lack of
automated testing.

Second patch to consolidate the code a bit and move invariant setup at engine
init time. Don't think I want to merge this one until some test coverage can be
had.

Tvrtko Ursulin (2):
  drm/i915: Do not cover all future platforms in TLB invalidation
  drm/i915: Consolidate TLB invalidation flow

 drivers/gpu/drm/i915/gt/intel_engine_cs.c    |  93 ++++++++++++++
 drivers/gpu/drm/i915/gt/intel_engine_types.h |  15 +++
 drivers/gpu/drm/i915/gt/intel_gt.c           | 124 +++----------------
 3 files changed, 128 insertions(+), 104 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 23+ messages in thread
* [PATCH 1/2] drm/i915: fix TLB invalidation for Gen12.50 video and compute engines
@ 2022-12-13 12:39 Tvrtko Ursulin
  2022-12-13 12:39 ` [Intel-gfx] [PATCH 2/2] drm/i915: Consolidate TLB invalidation flow Tvrtko Ursulin
  0 siblings, 1 reply; 23+ messages in thread
From: Tvrtko Ursulin @ 2022-12-13 12:39 UTC (permalink / raw)
  To: Intel-gfx, dri-devel; +Cc: Andrzej Hajda, Tvrtko Ursulin

From: Andrzej Hajda <andrzej.hajda@intel.com>

In case of Gen12.50 video and compute engines, TLB_INV registers are
masked - to modify one bit, corresponding bit in upper half of the register
must be enabled, otherwise nothing happens.

Fixes: 77fa9efc16a9 ("drm/i915/xehp: Create separate reg definitions for new MCR registers")
Signed-off-by: Andrzej Hajda <andrzej.hajda@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
 drivers/gpu/drm/i915/gt/intel_gt.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/gt/intel_gt.c b/drivers/gpu/drm/i915/gt/intel_gt.c
index 63f95c5f3614..7eeee5a7cb33 100644
--- a/drivers/gpu/drm/i915/gt/intel_gt.c
+++ b/drivers/gpu/drm/i915/gt/intel_gt.c
@@ -1100,9 +1100,15 @@ static void mmio_invalidate_full(struct intel_gt *gt)
 			continue;
 
 		if (GRAPHICS_VER_FULL(i915) >= IP_VER(12, 50)) {
+			u32 val = BIT(engine->instance);
+
+			if (engine->class == VIDEO_DECODE_CLASS ||
+			    engine->class == VIDEO_ENHANCEMENT_CLASS ||
+			    engine->class == COMPUTE_CLASS)
+				val = _MASKED_BIT_ENABLE(val);
 			intel_gt_mcr_multicast_write_fw(gt,
 							xehp_regs[engine->class],
-							BIT(engine->instance));
+							val);
 		} else {
 			rb = get_reg_and_bit(engine, regs == gen8_regs, regs, num);
 			if (!i915_mmio_reg_offset(rb.reg))
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2023-01-06  0:19 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-12-19 10:13 [PATCH 0/2] TLB invalidation cleanup Tvrtko Ursulin
2022-12-19 10:13 ` [Intel-gfx] " Tvrtko Ursulin
2022-12-19 10:13 ` [PATCH 1/2] drm/i915: Do not cover all future platforms in TLB invalidation Tvrtko Ursulin
2022-12-19 10:13   ` [Intel-gfx] " Tvrtko Ursulin
2022-12-19 15:40   ` Andrzej Hajda
2022-12-19 10:13 ` [PATCH 2/2] drm/i915: Consolidate TLB invalidation flow Tvrtko Ursulin
2022-12-19 10:13   ` [Intel-gfx] " Tvrtko Ursulin
2022-12-19 16:10   ` Andrzej Hajda
2023-01-03 19:57     ` Matt Roper
2023-01-03 19:57       ` Matt Roper
2023-01-04  8:46       ` Andrzej Hajda
2023-01-04 10:08       ` Tvrtko Ursulin
2023-01-04 17:41         ` Matt Roper
2023-01-04 21:58           ` Andrzej Hajda
2023-01-05 13:06           ` Tvrtko Ursulin
2023-01-06  0:19             ` Matt Roper
2022-12-19 14:40 ` [Intel-gfx] ✗ Fi.CI.SPARSE: warning for TLB invalidation cleanup Patchwork
2022-12-19 15:05 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2022-12-20  3:39 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2022-12-13 12:39 [PATCH 1/2] drm/i915: fix TLB invalidation for Gen12.50 video and compute engines Tvrtko Ursulin
2022-12-13 12:39 ` [Intel-gfx] [PATCH 2/2] drm/i915: Consolidate TLB invalidation flow Tvrtko Ursulin
2022-12-13 14:52   ` Andrzej Hajda
2022-12-13 15:22     ` Tvrtko Ursulin
2022-12-14  9:02       ` Andrzej Hajda

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.