Skip to content

Commit

Permalink
drm/amdgpu: fix a potential GPU hang on cyan skillfish
Browse files Browse the repository at this point in the history
commit bca5245 upstream.

We observed a GPU hang when querying GMC CG state(i.e.,
cat amdgpu_pm_info) on cyan skillfish. Acctually, cyan
skillfish doesn't support any CG features.

Just prevent it from accessing GMC CG registers.

Signed-off-by: Lang Yu <Lang.Yu@amd.com>
Reviewed-by: Lijo Lazar <lijo.lazar@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Lang Yu authored and gregkh committed Feb 8, 2022
1 parent 2738324 commit c51c6f1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/gpu/drm/amd/amdgpu/gmc_v10_0.c
Original file line number Diff line number Diff line change
Expand Up @@ -1147,6 +1147,9 @@ static void gmc_v10_0_get_clockgating_state(void *handle, u32 *flags)
{
struct amdgpu_device *adev = (struct amdgpu_device *)handle;

if (adev->ip_versions[GC_HWIP][0] == IP_VERSION(10, 1, 3))
return;

adev->mmhub.funcs->get_clockgating(adev, flags);

if (adev->ip_versions[ATHUB_HWIP][0] >= IP_VERSION(2, 1, 0))
Expand Down

0 comments on commit c51c6f1

Please sign in to comment.