drm/amdgpu/display: Allow DCC for video formats on GFX12
commit df1e82e7acd3c50b65ca0e2e09089b78382d14ab upstream. We advertise DCC as supported for NV12/P010 formats on GFX12, but it would fail on this check on atomic commit. Signed-off-by: David Rosca <david.rosca@amd.com> Reviewed-by: Ruijing Dong <ruijing.dong@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit ba795235a2b99ba9bbef647ab003b2f3145d9bbb) Cc: stable@vger.kernel.org # 6.12.x Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
c5c5e76aea
commit
60ae74e367
@@ -275,8 +275,11 @@ static int amdgpu_dm_plane_validate_dcc(struct amdgpu_device *adev,
|
||||
if (!dcc->enable)
|
||||
return 0;
|
||||
|
||||
if (format >= SURFACE_PIXEL_FORMAT_VIDEO_BEGIN ||
|
||||
!dc->cap_funcs.get_dcc_compression_cap)
|
||||
if (adev->family < AMDGPU_FAMILY_GC_12_0_0 &&
|
||||
format >= SURFACE_PIXEL_FORMAT_VIDEO_BEGIN)
|
||||
return -EINVAL;
|
||||
|
||||
if (!dc->cap_funcs.get_dcc_compression_cap)
|
||||
return -EINVAL;
|
||||
|
||||
input.format = format;
|
||||
|
||||
Reference in New Issue
Block a user