From: Matthew Auld <matthew.auld@intel.com>
To: intel-xe@lists.freedesktop.org
Cc: Dominik Grzegorzek <dominik.grzegorzek@intel.com>,
Mika Kuoppala <mika.kuoppala@linux.intel.com>,
Matthew Brost <matthew.brost@intel.com>
Subject: [PATCH] drm/xe: fix engine_class bounds check again
Date: Mon, 12 Aug 2024 15:13:32 +0100 [thread overview]
Message-ID: <20240812141331.729843-2-matthew.auld@intel.com> (raw)
This was fixed in commit b7dce525c4fc ("drm/xe/queue: fix engine_class
bounds check"), but then re-introduced in commit 6f20fc09936e ("drm/xe:
Move and export xe_hw_engine lookup.") which should only be simple code
movement of the existing function.
Fixes: 6f20fc09936e ("drm/xe: Move and export xe_hw_engine lookup.")
Signed-off-by: Matthew Auld <matthew.auld@intel.com>
Cc: Dominik Grzegorzek <dominik.grzegorzek@intel.com>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Cc: Matthew Brost <matthew.brost@intel.com>
---
drivers/gpu/drm/xe/xe_hw_engine.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/xe/xe_hw_engine.c b/drivers/gpu/drm/xe/xe_hw_engine.c
index 402dfa748e16..e195022ca836 100644
--- a/drivers/gpu/drm/xe/xe_hw_engine.c
+++ b/drivers/gpu/drm/xe/xe_hw_engine.c
@@ -1189,7 +1189,7 @@ xe_hw_engine_lookup(struct xe_device *xe,
{
unsigned int idx;
- if (eci.engine_class > ARRAY_SIZE(user_to_xe_engine_class))
+ if (eci.engine_class >= ARRAY_SIZE(user_to_xe_engine_class))
return NULL;
if (eci.gt_id >= xe->info.gt_count)
--
2.46.0
next reply other threads:[~2024-08-12 14:13 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-12 14:13 Matthew Auld [this message]
2024-08-12 14:22 ` [PATCH] drm/xe: fix engine_class bounds check again Cavitt, Jonathan
2024-08-12 14:30 ` ✓ CI.Patch_applied: success for " Patchwork
2024-08-12 14:31 ` ✓ CI.checkpatch: " Patchwork
2024-08-12 14:32 ` ✓ CI.KUnit: " Patchwork
2024-08-12 14:44 ` ✓ CI.Build: " Patchwork
2024-08-12 14:46 ` ✓ CI.Hooks: " Patchwork
2024-08-12 14:47 ` ✓ CI.checksparse: " Patchwork
2024-08-12 15:08 ` ✓ CI.BAT: " Patchwork
2024-08-12 20:01 ` ✗ CI.FULL: failure " Patchwork
2024-08-15 19:23 ` [PATCH] " Lucas De Marchi
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=20240812141331.729843-2-matthew.auld@intel.com \
--to=matthew.auld@intel.com \
--cc=dominik.grzegorzek@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=matthew.brost@intel.com \
--cc=mika.kuoppala@linux.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