On Thu, Jan 5, 2023 at 2:11 PM Christian König <ckoenig.leichtzumerken@xxxxxxxxx> wrote: > > Am 05.01.23 um 17:50 schrieb Alex Deucher: > > On Thu, Jan 5, 2023 at 6:17 AM Christian König > > <ckoenig.leichtzumerken@xxxxxxxxx> wrote: > >> When the fence can't be added we need to drop the reference. > >> > >> Suggested-by: Bert Karwatzki <spasswolf@xxxxxx> > >> Signed-off-by: Christian König <christian.koenig@xxxxxxx> > > please add: > > Cc: stable@xxxxxxxxxxxxxxx # 6.1.x > > When you push this series. > > But none of this is in 6.1? That are pure 6.2 changes or am I missing > something? I thought patch 1 fixed an issue in the gang submit code which was in 6.1, or was that fixing an issue in a subsequent change? Alex > > Christian. > > > > > Alex > > > >> --- > >> 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; > >> } > >> -- > >> 2.34.1 > >> >