> -----Original Message----- > From: amd-gfx [mailto:amd-gfx-bounces at lists.freedesktop.org] On Behalf > Of Tom St Denis > Sent: Thursday, August 11, 2016 10:33 AM > To: amd-gfx at lists.freedesktop.org > Cc: StDenis, Tom > Subject: [PATCH 2/4] drm/amd/amdgpu: add mutex in check_soft for VCE v3 > > Signed-off-by: Tom St Denis <tom.stdenis at amd.com> Reviewed-by: Alex Deucher <alexander.deucher at amd.com> > --- > drivers/gpu/drm/amd/amdgpu/vce_v3_0.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/drivers/gpu/drm/amd/amdgpu/vce_v3_0.c > b/drivers/gpu/drm/amd/amdgpu/vce_v3_0.c > index 073cf9ed0674..615b8b16ad04 100644 > --- a/drivers/gpu/drm/amd/amdgpu/vce_v3_0.c > +++ b/drivers/gpu/drm/amd/amdgpu/vce_v3_0.c > @@ -569,6 +569,7 @@ static int vce_v3_0_check_soft_reset(void *handle) > * > * VCE team suggest use bit 3--bit 6 for busy status check > */ > + mutex_lock(&adev->grbm_idx_mutex); > WREG32_FIELD(GRBM_GFX_INDEX, INSTANCE_INDEX, 0); > if (RREG32(mmVCE_STATUS) & > AMDGPU_VCE_STATUS_BUSY_MASK) { > srbm_soft_reset = REG_SET_FIELD(srbm_soft_reset, > SRBM_SOFT_RESET, SOFT_RESET_VCE0, 1); > @@ -588,6 +589,7 @@ static int vce_v3_0_check_soft_reset(void *handle) > adev->ip_block_status[AMD_IP_BLOCK_TYPE_VCE].hang = > false; > adev->vce.srbm_soft_reset = 0; > } > + mutex_unlock(&adev->grbm_idx_mutex); > return 0; > } > > -- > 2.9.2 > > _______________________________________________ > amd-gfx mailing list > amd-gfx at lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/amd-gfx