drm/amdgpu: fix r initial values
authorVictor Zhao <Victor.Zhao@amd.com>
Tue, 27 Apr 2021 09:52:56 +0000 (17:52 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 10 May 2021 22:06:42 +0000 (18:06 -0400)
Sriov gets suspend of IP block <dce_virtual> failed as return
value was not initialized.

v2: return 0 directly to align original code semantic before this
was broken out into a separate helper function instead of setting
initial values

Signed-off-by: Victor Zhao <Victor.Zhao@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_display.c

index 2e622c1675d7ad79829417deb83a4cc5a4c53faa..d3ae674b432b6549bab4a159fa0bf546a746e888 100644 (file)
@@ -1412,7 +1412,7 @@ int amdgpu_display_suspend_helper(struct amdgpu_device *adev)
                        }
                }
        }
-       return r;
+       return 0;
 }
 
 int amdgpu_display_resume_helper(struct amdgpu_device *adev)