From: Shuicheng Lin <shuicheng.lin@intel.com>
To: intel-xe@lists.freedesktop.org
Cc: Shuicheng Lin <shuicheng.lin@intel.com>,
Matthew Brost <matthew.brost@intel.com>,
Niranjana Vishwanathapura <niranjana.vishwanathapura@intel.com>
Subject: [PATCH 2/2] drm/xe: Fix exec queue unwind on hw engine group add failure
Date: Fri, 6 Mar 2026 03:00:10 +0000 [thread overview]
Message-ID: <20260306030010.11041-3-shuicheng.lin@intel.com> (raw)
In-Reply-To: <20260306030010.11041-1-shuicheng.lin@intel.com>
When xe_hw_engine_group_add_exec_queue() fails in
xe_exec_queue_create_ioctl(), to undo xe_exec_queue_group_add()
and xe_vm_add_compute_exec_queue(), the code should unwind through
kill_exec_queue rather than directly dropping the queue reference.
v2: correct the jump label. (Matt)
Fixes: d9ec63474648 ("drm/xe/multi_queue: Add user interface for multi queue support")
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Cc: Niranjana Vishwanathapura <niranjana.vishwanathapura@intel.com>
Signed-off-by: Shuicheng Lin <shuicheng.lin@intel.com>
---
drivers/gpu/drm/xe/xe_exec_queue.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/xe/xe_exec_queue.c b/drivers/gpu/drm/xe/xe_exec_queue.c
index af915ccb4925..372fc17a2f46 100644
--- a/drivers/gpu/drm/xe/xe_exec_queue.c
+++ b/drivers/gpu/drm/xe/xe_exec_queue.c
@@ -1390,7 +1390,7 @@ int xe_exec_queue_create_ioctl(struct drm_device *dev, void *data,
if (q->vm && q->hwe->hw_engine_group) {
err = xe_hw_engine_group_add_exec_queue(q->hwe->hw_engine_group, q);
if (err)
- goto put_exec_queue;
+ goto kill_exec_queue;
}
}
--
2.34.1
prev parent reply other threads:[~2026-03-06 3:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-06 3:00 [PATCH 0/2] Fix error path of xe_exec_queue_create_ioctl() Shuicheng Lin
2026-03-06 3:00 ` [PATCH 1/2] drm/xe: Fix missing xe_hw_engine_group_del_exec_queue() in error path Shuicheng Lin
2026-03-06 3:00 ` Shuicheng Lin [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260306030010.11041-3-shuicheng.lin@intel.com \
--to=shuicheng.lin@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=matthew.brost@intel.com \
--cc=niranjana.vishwanathapura@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox