Commit a6ea0a43 authored by Alan Liu's avatar Alan Liu Committed by Alex Deucher
Browse files

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: default avatarLang Yu <lang.yu@amd.com>
Signed-off-by: default avatarAlan Liu <haoping.liu@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 0099f2e9
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -201,6 +201,9 @@ static enum amd_ip_block_type
		type = (amdgpu_device_ip_get_ip_block(adev, AMD_IP_BLOCK_TYPE_JPEG)) ?
				   AMD_IP_BLOCK_TYPE_JPEG : AMD_IP_BLOCK_TYPE_VCN;
		break;
	case AMDGPU_HW_IP_VPE:
		type = AMD_IP_BLOCK_TYPE_VPE;
		break;
	default:
		type = AMD_IP_BLOCK_TYPE_NUM;
		break;
@@ -757,6 +760,9 @@ int amdgpu_info_ioctl(struct drm_device *dev, void *data, struct drm_file *filp)
		case AMD_IP_BLOCK_TYPE_UVD:
			count = adev->uvd.num_uvd_inst;
			break;
		case AMD_IP_BLOCK_TYPE_VPE:
			count = adev->vpe.num_instances;
			break;
		/* For all other IP block types not listed in the switch statement
		 * the ip status is valid here and the instance count is one.
		 */