All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Christian König" <ckoenig.leichtzumerken@gmail.com>
To: Roy Sun <Roy.Sun@amd.com>, amd-gfx@lists.freedesktop.org
Cc: Alexander.Deucher@amd.com, David M Nieto <david.nieto@amd.com>
Subject: Re: [PATCH 2/2] drm/scheduler: Change scheduled fence track
Date: Wed, 7 Apr 2021 16:04:04 +0200	[thread overview]
Message-ID: <beb308cb-f1b9-f2c8-263d-b8aea85b5436@gmail.com> (raw)
In-Reply-To: <20210407133105.39702-2-Roy.Sun@amd.com>



Am 07.04.21 um 15:31 schrieb Roy Sun:
> Update the timestamp of scheduled fence on HW
> completion of the previous fences
>
> This allow more accurate tracking of the fence
> execution in HW
>
> Signed-off-by: David M Nieto <david.nieto@amd.com>
> Signed-off-by: Roy Sun <Roy.Sun@amd.com>
> ---
>   drivers/gpu/drm/scheduler/sched_main.c | 11 +++++++++--
>   1 file changed, 9 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/scheduler/sched_main.c b/drivers/gpu/drm/scheduler/sched_main.c
> index 92d8de24d0a1..4e5d8d4af010 100644
> --- a/drivers/gpu/drm/scheduler/sched_main.c
> +++ b/drivers/gpu/drm/scheduler/sched_main.c
> @@ -515,7 +515,7 @@ void drm_sched_resubmit_jobs(struct drm_gpu_scheduler *sched)
>   EXPORT_SYMBOL(drm_sched_resubmit_jobs);
>   
>   /**
> - * drm_sched_resubmit_jobs_ext - helper to relunch certain number of jobs from mirror ring list
> + * drm_sched_resubmit_jobs_ext - helper to relunch certain number of jobs from pending list

s/relunch/relaunch/

With that nit pick fixed the patch is Reviewed-by: Christian König 
<christian.koenig@amd.com>

>    *
>    * @sched: scheduler instance
>    * @max: job numbers to relaunch
> @@ -671,7 +671,7 @@ drm_sched_select_entity(struct drm_gpu_scheduler *sched)
>   static struct drm_sched_job *
>   drm_sched_get_cleanup_job(struct drm_gpu_scheduler *sched)
>   {
> -	struct drm_sched_job *job;
> +	struct drm_sched_job *job, *next;
>   
>   	/*
>   	 * Don't destroy jobs while the timeout worker is running  OR thread
> @@ -690,6 +690,13 @@ drm_sched_get_cleanup_job(struct drm_gpu_scheduler *sched)
>   	if (job && dma_fence_is_signaled(&job->s_fence->finished)) {
>   		/* remove job from pending_list */
>   		list_del_init(&job->list);
> +		/* account for the next fence in the queue */
> +		next = list_first_entry_or_null(&sched->pending_list,
> +				struct drm_sched_job, list);
> +		if (next) {
> +			next->s_fence->scheduled.timestamp =
> +				job->s_fence->finished.timestamp;
> +		}
>   	} else {
>   		job = NULL;
>   		/* queue timeout for next job */

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

  reply	other threads:[~2021-04-07 14:04 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-07 13:31 [PATCH 1/2] drm/amdgpu: Add show_fdinfo() interface Roy Sun
2021-04-07 13:31 ` [PATCH 2/2] drm/scheduler: Change scheduled fence track Roy Sun
2021-04-07 14:04   ` Christian König [this message]
2021-04-07 15:44   ` Alex Deucher
2021-04-07 15:44     ` Alex Deucher
2021-04-07 14:20 ` [PATCH 1/2] drm/amdgpu: Add show_fdinfo() interface Christian König

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=beb308cb-f1b9-f2c8-263d-b8aea85b5436@gmail.com \
    --to=ckoenig.leichtzumerken@gmail.com \
    --cc=Alexander.Deucher@amd.com \
    --cc=Roy.Sun@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=david.nieto@amd.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.