From: Matthew Auld <matthew.auld@intel.com>
To: intel-xe@lists.freedesktop.org
Cc: Nirmoy Das <nirmoy.das@intel.com>
Subject: [PATCH 2/2] drm/xe/bb: assert width in xe_bb_create_migration_job()
Date: Wed, 20 Mar 2024 11:27:32 +0000 [thread overview]
Message-ID: <20240320112730.219854-4-matthew.auld@intel.com> (raw)
In-Reply-To: <20240320112730.219854-3-matthew.auld@intel.com>
The q->width should always be exactly one here for migration queue/vm.
The width will anyway be overridden later since we need to emit two
jumps for special migration jobs. Enforce that here to ensure caller is
not doing something strange. While here also convert to the helper to
determine if the queue is migration based.
Signed-off-by: Matthew Auld <matthew.auld@intel.com>
Cc: Nirmoy Das <nirmoy.das@intel.com>
---
drivers/gpu/drm/xe/xe_bb.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/xe/xe_bb.c b/drivers/gpu/drm/xe/xe_bb.c
index a35e0781b7b9..541361caff3b 100644
--- a/drivers/gpu/drm/xe/xe_bb.c
+++ b/drivers/gpu/drm/xe/xe_bb.c
@@ -86,7 +86,8 @@ struct xe_sched_job *xe_bb_create_migration_job(struct xe_exec_queue *q,
};
xe_gt_assert(q->gt, second_idx <= bb->len);
- xe_gt_assert(q->gt, q->vm->flags & XE_VM_FLAG_MIGRATION);
+ xe_gt_assert(q->gt, xe_sched_job_is_migration(q));
+ xe_gt_assert(q->gt, q->width == 1);
return __xe_bb_create_job(q, bb, addr);
}
--
2.44.0
next prev parent reply other threads:[~2024-03-20 11:28 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-20 11:27 [PATCH 1/2] drm/xe/bb: assert width in xe_bb_create_job() Matthew Auld
2024-03-20 11:27 ` Matthew Auld [this message]
2024-03-20 12:50 ` [PATCH 2/2] drm/xe/bb: assert width in xe_bb_create_migration_job() Nirmoy Das
2024-03-20 11:58 ` ✓ CI.Patch_applied: success for series starting with [1/2] drm/xe/bb: assert width in xe_bb_create_job() Patchwork
2024-03-20 11:59 ` ✓ CI.checkpatch: " Patchwork
2024-03-20 11:59 ` ✓ CI.KUnit: " Patchwork
2024-03-20 12:10 ` ✓ CI.Build: " Patchwork
2024-03-20 12:13 ` ✓ CI.Hooks: " Patchwork
2024-03-20 12:14 ` ✓ CI.checksparse: " Patchwork
2024-03-20 12:39 ` ✓ CI.BAT: " Patchwork
2024-03-20 12:49 ` [PATCH 1/2] " Nirmoy Das
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=20240320112730.219854-4-matthew.auld@intel.com \
--to=matthew.auld@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=nirmoy.das@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