Skip to content

Commit cb4b02d

Browse files
zming6666alexdeucher
authored andcommitted
drm/amdgpu: return -ENOENT from uvd 6.0 early init for harvesting
Fixes init failures on polaris cards with harvested UVD. Signed-off-by: Leo Liu <leo.liu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
1 parent d3daa2c commit cb4b02d

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,10 @@ static int uvd_v6_0_early_init(void *handle)
9393
{
9494
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
9595

96+
if (!(adev->flags & AMD_IS_APU) &&
97+
(RREG32_SMC(ixCC_HARVEST_FUSES) & CC_HARVEST_FUSES__UVD_DISABLE_MASK))
98+
return -ENOENT;
99+
96100
uvd_v6_0_set_ring_funcs(adev);
97101
uvd_v6_0_set_irq_funcs(adev);
98102

0 commit comments

Comments
 (0)