Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/amdgpu: Fix query for VPE block_type and ip_count

[Why]
Query for VPE block_type and ip_count is missing.

[How]
Add VPE case in ip_block_type and hw_ip_count query.

Reviewed-by: Lang Yu <lang.yu@amd.com>
Signed-off-by: Alan Liu <haoping.liu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
(cherry picked from commit a6ea0a430aca5932b9c75d8e38deeb45665dd2ae)
Cc: stable@vger.kernel.org

authored by

Alan Liu and committed by
Alex Deucher
72d7f457 e0d20a76

+6
+6
drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
··· 201 201 type = (amdgpu_device_ip_get_ip_block(adev, AMD_IP_BLOCK_TYPE_JPEG)) ? 202 202 AMD_IP_BLOCK_TYPE_JPEG : AMD_IP_BLOCK_TYPE_VCN; 203 203 break; 204 + case AMDGPU_HW_IP_VPE: 205 + type = AMD_IP_BLOCK_TYPE_VPE; 206 + break; 204 207 default: 205 208 type = AMD_IP_BLOCK_TYPE_NUM; 206 209 break; ··· 723 720 break; 724 721 case AMD_IP_BLOCK_TYPE_UVD: 725 722 count = adev->uvd.num_uvd_inst; 723 + break; 724 + case AMD_IP_BLOCK_TYPE_VPE: 725 + count = adev->vpe.num_instances; 726 726 break; 727 727 /* For all other IP block types not listed in the switch statement 728 728 * the ip status is valid here and the instance count is one.