From: Alex Deucher Date: Wed, 26 Apr 2023 18:42:09 +0000 (-0400) Subject: drm/amdgpu/gfx10: drop unused variable X-Git-Tag: v6.6.7~2401^2~12^2~684 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d78e816a3d615073a48bf8cc438790bc08160e0e;p=platform%2Fkernel%2Flinux-starfive.git drm/amdgpu/gfx10: drop unused variable Just check the return value directly. Reviewed-by: Christian König Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c index 24d7134..5c67c91 100644 --- a/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c +++ b/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c @@ -7159,15 +7159,13 @@ static int gfx_v10_0_hw_init(void *handle) static int gfx_v10_0_hw_fini(void *handle) { struct amdgpu_device *adev = (struct amdgpu_device *)handle; - int r; amdgpu_irq_put(adev, &adev->gfx.priv_reg_irq, 0); amdgpu_irq_put(adev, &adev->gfx.priv_inst_irq, 0); if (!adev->no_hw_access) { if (amdgpu_async_gfx_ring) { - r = amdgpu_gfx_disable_kgq(adev, 0); - if (r) + if (amdgpu_gfx_disable_kgq(adev, 0)) DRM_ERROR("KGQ disable failed\n"); }