From: Nirmoy Das <nirmoy.das@linux.intel.com>
To: Lucas De Marchi <lucas.demarchi@intel.com>,
Nirmoy Das <nirmoy.das@intel.com>
Cc: intel-xe@lists.freedesktop.org,
Matthew Auld <matthew.auld@intel.com>,
Matthew Brost <matthew.brost@intel.com>,
Michal Wajdeczko <michal.wajdeczko@intel.com>
Subject: Re: [PATCH v2] drm/xe: Create a helper function to init job's user fence
Date: Mon, 25 Mar 2024 21:54:31 +0100 [thread overview]
Message-ID: <8c521ff9-950f-480e-911b-9c6210ff6416@linux.intel.com> (raw)
In-Reply-To: <vgkvzpqwyku2q5lomqvytpeuz7hvybykd4rnetzkgy3siy3c57@jclsubzhsmts>
Hi Lucas,
On 3/22/2024 5:11 PM, Lucas De Marchi wrote:
> On Thu, Mar 21, 2024 at 05:11:42PM +0100, Nirmoy Das wrote:
>> Refactor xe_sync_entry_signal so it doesn't have to
>> modify xe_sched_job struct instead create a new helper function
>> to set user fence values for a job.
>>
>> v2: Move the sync type check to xe_sched_job_init_user_fence(Lucas)
>>
>> Cc: Lucas De Marchi <lucas.demarchi@intel.com>
>> Cc: Matthew Auld <matthew.auld@intel.com>
>> Cc: Matthew Brost <matthew.brost@intel.com>
>> Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
>> Signed-off-by: Nirmoy Das <nirmoy.das@intel.com>
>> ---
>> drivers/gpu/drm/xe/xe_exec.c | 9 +++++----
>> drivers/gpu/drm/xe/xe_sched_job.c | 18 ++++++++++++++++++
>> drivers/gpu/drm/xe/xe_sched_job.h | 3 +++
>> drivers/gpu/drm/xe/xe_sync.c | 7 +------
>> drivers/gpu/drm/xe/xe_sync.h | 1 -
>> drivers/gpu/drm/xe/xe_vm.c | 10 +++++-----
>> 6 files changed, 32 insertions(+), 16 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/xe/xe_exec.c b/drivers/gpu/drm/xe/xe_exec.c
>> index 7692ebfe7d47..9d53ef8c49cc 100644
>> --- a/drivers/gpu/drm/xe/xe_exec.c
>> +++ b/drivers/gpu/drm/xe/xe_exec.c
>> @@ -249,7 +249,7 @@ int xe_exec_ioctl(struct drm_device *dev, void
>> *data, struct drm_file *file)
>> goto err_unlock_list;
>> }
>> for (i = 0; i < num_syncs; i++)
>> - xe_sync_entry_signal(&syncs[i], NULL, fence);
>> + xe_sync_entry_signal(&syncs[i], fence);
>> xe_exec_queue_last_fence_set(q, vm, fence);
>> dma_fence_put(fence);
>> }
>> @@ -359,9 +359,10 @@ int xe_exec_ioctl(struct drm_device *dev, void
>> *data, struct drm_file *file)
>> drm_gpuvm_resv_add_fence(&vm->gpuvm, exec,
>> &job->drm.s_fence->finished,
>> DMA_RESV_USAGE_BOOKKEEP, DMA_RESV_USAGE_WRITE);
>>
>> - for (i = 0; i < num_syncs; i++)
>> - xe_sync_entry_signal(&syncs[i], job,
>> - &job->drm.s_fence->finished);
>> + for (i = 0; i < num_syncs; i++) {
>> + xe_sync_entry_signal(&syncs[i], &job->drm.s_fence->finished);
>> + xe_sched_job_init_user_fence(job, &syncs[i]);
>> + }
>>
>> if (xe_exec_queue_is_lr(q))
>> q->ring_ops->emit_job(job);
>> diff --git a/drivers/gpu/drm/xe/xe_sched_job.c
>> b/drivers/gpu/drm/xe/xe_sched_job.c
>> index 8151ddafb940..bfbce9b69087 100644
>> --- a/drivers/gpu/drm/xe/xe_sched_job.c
>> +++ b/drivers/gpu/drm/xe/xe_sched_job.c
>> @@ -5,6 +5,7 @@
>>
>> #include "xe_sched_job.h"
>>
>> +#include <drm/xe_drm.h>
>> #include <linux/dma-fence-array.h>
>> #include <linux/slab.h>
>>
>> @@ -17,6 +18,7 @@
>> #include "xe_macros.h"
>> #include "xe_trace.h"
>> #include "xe_vm.h"
>> +#include "xe_sync_types.h"
>
> wrong placement, otherwise lgtm
>
> Feel free to carry by Reviewed-by: Lucas De Marchi
> <lucas.demarchi@intel.com>
> with that fixed.
Could you please help me merge this patch. I am having issue with my
dev machine which I use to merge patches.
I can re-send with the above change as you have suggested.
Regards,
Nirmoy
>
> thanks
> Lucas De Marchi
next prev parent reply other threads:[~2024-03-25 20:54 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-21 16:11 [PATCH v2] drm/xe: Create a helper function to init job's user fence Nirmoy Das
2024-03-21 20:18 ` ✓ CI.Patch_applied: success for drm/xe: Create a helper function to init job's user fence (rev2) Patchwork
2024-03-21 20:19 ` ✓ CI.checkpatch: " Patchwork
2024-03-21 20:19 ` ✓ CI.KUnit: " Patchwork
2024-03-21 20:30 ` ✓ CI.Build: " Patchwork
2024-03-21 20:33 ` ✓ CI.Hooks: " Patchwork
2024-03-21 20:34 ` ✓ CI.checksparse: " Patchwork
2024-03-21 20:56 ` ✓ CI.BAT: " Patchwork
2024-03-22 16:11 ` [PATCH v2] drm/xe: Create a helper function to init job's user fence Lucas De Marchi
2024-03-25 20:54 ` Nirmoy Das [this message]
2024-03-26 22:56 ` Lucas De Marchi
2024-03-27 16:48 ` 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=8c521ff9-950f-480e-911b-9c6210ff6416@linux.intel.com \
--to=nirmoy.das@linux.intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=lucas.demarchi@intel.com \
--cc=matthew.auld@intel.com \
--cc=matthew.brost@intel.com \
--cc=michal.wajdeczko@intel.com \
--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