]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-client.git/commit
drm/xe/wa: Steer RMW of MCR registers while building default LRC
authorMatt Roper <matthew.d.roper@intel.com>
Fri, 6 Feb 2026 22:30:59 +0000 (14:30 -0800)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Mon, 23 Feb 2026 18:54:48 +0000 (13:54 -0500)
commit43d37df67f7770d8d261fdcb64ecc8c314e91303
treeb2fe51dad1e1a7f09d9b1ea57e24455b882b4509
parent6de23f81a5e08be8fbf5e8d7e9febc72a5b5f27f
drm/xe/wa: Steer RMW of MCR registers while building default LRC

When generating the default LRC, if a register is not masked, we apply
any save-restore programming necessary via a read-modify-write sequence
that will ensure we only update the relevant bits/fields without
clobbering the rest of the register.  However some of the registers that
need to be updated might be MCR registers which require steering to a
non-terminated instance to ensure we can read back a valid, non-zero
value. The steering of reads originating from a command streamer is
controlled by register CS_MMIO_GROUP_INSTANCE_SELECT.  Emit additional
MI_LRI commands to update the steering before any RMW of an MCR register
to ensure the reads are performed properly.

Note that needing to perform a RMW of an MCR register while building the
default LRC is pretty rare.  Most of the MCR registers that are part of
an engine's LRCs are also masked registers, so no MCR is necessary.

Fixes: f2f90989ccff ("drm/xe: Avoid reading RMW registers in emit_wa_job")
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
Reviewed-by: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
Link: https://patch.msgid.link/20260206223058.387014-2-matthew.d.roper@intel.com
Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
(cherry picked from commit 6c2e331c915ba9e774aa847921262805feb00863)
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
drivers/gpu/drm/xe/regs/xe_engine_regs.h
drivers/gpu/drm/xe/xe_gt.c