public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Shashank Sharma <shashank.sharma@amd.com>
To: Arvind Yadav <Arvind.Yadav@amd.com>,
	Christian.Koenig@amd.com, alexander.deucher@amd.com,
	Xinhui.Pan@amd.com, airlied@gmail.com, daniel@ffwll.ch,
	Felix.Kuehling@amd.com, amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 5/7] drm/amdgpu: Switch on/off GPU workload profile
Date: Mon, 21 Aug 2023 15:46:42 +0200	[thread overview]
Message-ID: <5436e99a-fb23-29cb-d20f-48fb91d57950@amd.com> (raw)
In-Reply-To: <20230821064759.94223-6-Arvind.Yadav@amd.com>


On 21/08/2023 08:47, Arvind Yadav wrote:
> This patch is to switch the GPU workload profile based
> on the submitted job. The workload profile is reset to
> default when the job is done.
>
> Cc: Shashank Sharma <shashank.sharma@amd.com>
> Cc: Christian Koenig <christian.koenig@amd.com>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Signed-off-by: Arvind Yadav <Arvind.Yadav@amd.com>
> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 5 +++++
>   1 file changed, 5 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_job.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_job.c
> index c3d9d75143f4..c2b0fda6ba26 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_job.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_job.c
> @@ -176,6 +176,9 @@ void amdgpu_job_free_resources(struct amdgpu_job *job)
>   static void amdgpu_job_free_cb(struct drm_sched_job *s_job)
>   {
>   	struct amdgpu_job *job = to_amdgpu_job(s_job);
> +	struct amdgpu_ring *ring = to_amdgpu_ring(s_job->sched);
> +
> +	amdgpu_workload_profile_put(ring->adev, ring->funcs->type);
>   
>   	drm_sched_job_cleanup(s_job);
>   
> @@ -295,6 +298,8 @@ static struct dma_fence *amdgpu_job_run(struct drm_sched_job *sched_job)
>   			DRM_ERROR("Error scheduling IBs (%d)\n", r);
>   	}
>   
> +	amdgpu_workload_profile_set(adev, ring->funcs->type);
> +
>   	job->job_run_counter++;
>   	amdgpu_job_free_resources(job);
>   

Instead of calling switch on/off in title, may we call it set/reset GPU 
workload profile ?

With that minor nitpick handled, please feel free to use:

Reviewed-by: Shashank Sharma <shashank.sharma@amd.com>

- Shashank


  reply	other threads:[~2023-08-21 13:47 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-21  6:47 [PATCH v2 0/7] GPU workload hints for better performance Arvind Yadav
2023-08-21  6:47 ` [PATCH v2 1/7] drm/amdgpu: Added init/fini functions for workload Arvind Yadav
2023-08-21 13:06   ` Shashank Sharma
2023-08-21 13:35     ` Yadav, Arvind
2023-08-21 13:54       ` Shashank Sharma
2023-08-21 14:12         ` Yadav, Arvind
2023-08-21 14:27           ` Shashank Sharma
2023-08-21  6:47 ` [PATCH v2 2/7] drm/amdgpu: Add new function to set GPU power profile Arvind Yadav
2023-08-21 13:10   ` Shashank Sharma
2023-08-21 16:22   ` Alex Deucher
2023-08-21 17:53     ` Yadav, Arvind
2023-08-21 18:10       ` Alex Deucher
2023-08-22  6:13         ` Yadav, Arvind
2023-08-21 18:06   ` Alex Deucher
2023-08-21 18:08     ` Yadav, Arvind
2023-08-22  6:25   ` Lazar, Lijo
2023-08-22 12:40     ` Yadav, Arvind
2023-08-21  6:47 ` [PATCH v2 3/7] drm/amdgpu: Add new function to put " Arvind Yadav
2023-08-21 13:39   ` Shashank Sharma
2023-08-21 14:40     ` Yadav, Arvind
2023-08-22  4:51   ` Lazar, Lijo
2023-08-22 12:11     ` Yadav, Arvind
2023-08-22 12:46       ` Lazar, Lijo
2023-08-25 11:18         ` Yadav, Arvind
2023-08-25 11:27           ` Lazar, Lijo
2023-08-21  6:47 ` [PATCH v2 4/7] drm/amdgpu: Add suspend function to clear the " Arvind Yadav
2023-08-21 13:43   ` Shashank Sharma
2023-08-21 13:52     ` Yadav, Arvind
2023-08-22  6:31   ` Lazar, Lijo
2023-08-22 12:22     ` Yadav, Arvind
2023-08-22 12:54       ` Lazar, Lijo
2023-08-22 12:56         ` Yadav, Arvind
2023-08-21  6:47 ` [PATCH v2 5/7] drm/amdgpu: Switch on/off GPU workload profile Arvind Yadav
2023-08-21 13:46   ` Shashank Sharma [this message]
2023-08-21 13:53     ` Yadav, Arvind
2023-08-21  6:47 ` [PATCH v2 6/7] drm/amdgpu: switch workload context to/from compute Arvind Yadav
2023-08-21 13:47   ` Shashank Sharma
2023-08-21  6:47 ` [PATCH v2 7/7] Revert "drm/amd/amdgpu: switch on/off vcn power profile mode" Arvind Yadav
2023-08-21 13:49   ` Shashank Sharma

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=5436e99a-fb23-29cb-d20f-48fb91d57950@amd.com \
    --to=shashank.sharma@amd.com \
    --cc=Arvind.Yadav@amd.com \
    --cc=Christian.Koenig@amd.com \
    --cc=Felix.Kuehling@amd.com \
    --cc=Xinhui.Pan@amd.com \
    --cc=airlied@gmail.com \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    /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