Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2] drm/xe: restrict multi-lrc to VCS/VECS engines
@ 2026-02-18 23:38 Xin Wang
  2026-02-19  0:41 ` ✓ CI.KUnit: success for " Patchwork
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Xin Wang @ 2026-02-18 23:38 UTC (permalink / raw)
  To: intel-xe; +Cc: Xin Wang, Shuicheng Lin, Matt Roper

Tighten uapi validation to restrict multi-lrc support to VIDEO_DECODE and
VIDEO_ENHANCE engines only. This check should have been in place from the
start, as the driver typically avoids allowing uapi cases that we have
no userspace consumer for.

Additionally, the GuC firmware on ModSched platforms no longer supports
multi-lrc on non-media engines.

V2:
 - correct the typo (Shuicheng)
 - move the check earlier to avoid VM lookup (Shuicheng, Matt)
 - remove the graphics version check (Matt)
 - input more details in the commit info (Matt)

Cc: Shuicheng Lin <shuicheng.lin@intel.com>
Cc: Matt Roper <matthew.d.roper@intel.com>
Signed-off-by: Xin Wang <x.wang@intel.com>
---
 drivers/gpu/drm/xe/xe_exec_queue.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/gpu/drm/xe/xe_exec_queue.c b/drivers/gpu/drm/xe/xe_exec_queue.c
index 66d0e10ee2c4..36bf570ab221 100644
--- a/drivers/gpu/drm/xe/xe_exec_queue.c
+++ b/drivers/gpu/drm/xe/xe_exec_queue.c
@@ -1184,6 +1184,12 @@ int xe_exec_queue_create_ioctl(struct drm_device *dev, void *data,
 		if (XE_IOCTL_DBG(xe, !hwe))
 			return -EINVAL;
 
+		/* multi-lrc is only supported on VIDEO_DECODE and VIDEO_ENHANCE engines */
+		if (XE_IOCTL_DBG(xe, args->width > 1 &&
+				 eci[0].engine_class != DRM_XE_ENGINE_CLASS_VIDEO_DECODE &&
+				 eci[0].engine_class != DRM_XE_ENGINE_CLASS_VIDEO_ENHANCE))
+			return -EOPNOTSUPP;
+
 		vm = xe_vm_lookup(xef, args->vm_id);
 		if (XE_IOCTL_DBG(xe, !vm))
 			return -ENOENT;
-- 
2.43.0


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

end of thread, other threads:[~2026-02-19 18:11 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-18 23:38 [PATCH v2] drm/xe: restrict multi-lrc to VCS/VECS engines Xin Wang
2026-02-19  0:41 ` ✓ CI.KUnit: success for " Patchwork
2026-02-19  1:16 ` ✓ Xe.CI.BAT: " Patchwork
2026-02-19  2:21 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-02-19 18:10 ` [PATCH v2] " Matthew Brost

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox