From: Luben Tuikov <luben.tuikov@amd.com>
To: "Christian König" <ckoenig.leichtzumerken@gmail.com>,
amd-gfx@lists.freedesktop.org
Subject: Re: [PATCH 2/2] drm/amdgpu: fix missing dma_fence_put in error path
Date: Thu, 5 Jan 2023 11:12:10 -0500 [thread overview]
Message-ID: <7f990e92-e30c-86c7-0d8a-555bfbeb5eb3@amd.com> (raw)
In-Reply-To: <20230105111703.52695-2-christian.koenig@amd.com>
Series is:
Reviewed-by: Luben Tuikov <luben.tuikov@amd.com>
Regards,
Luben
On 2023-01-05 06:17, Christian König wrote:
> When the fence can't be added we need to drop the reference.
>
> Suggested-by: Bert Karwatzki <spasswolf@web.de>
> Signed-off-by: Christian König <christian.koenig@amd.com>
> ---
> drivers/gpu/drm/amd/amdgpu/amdgpu_sync.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_sync.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_sync.c
> index bac7976975bd..dcd8c066bc1f 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_sync.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_sync.c
> @@ -391,8 +391,10 @@ int amdgpu_sync_push_to_job(struct amdgpu_sync *sync, struct amdgpu_job *job)
>
> dma_fence_get(f);
> r = drm_sched_job_add_dependency(&job->base, f);
> - if (r)
> + if (r) {
> + dma_fence_put(f);
> return r;
> + }
> }
> return 0;
> }
next prev parent reply other threads:[~2023-01-05 16:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-05 11:17 [PATCH 1/2] drm/amdgpu: fix another missing fence reference in the CS code Christian König
2023-01-05 11:17 ` [PATCH 2/2] drm/amdgpu: fix missing dma_fence_put in error path Christian König
2023-01-05 14:35 ` Alex Deucher
2023-01-05 16:12 ` Luben Tuikov [this message]
2023-01-05 16:50 ` Alex Deucher
2023-01-05 19:11 ` Christian König
2023-01-05 19:26 ` Alex Deucher
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=7f990e92-e30c-86c7-0d8a-555bfbeb5eb3@amd.com \
--to=luben.tuikov@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=ckoenig.leichtzumerken@gmail.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.