Commit 56ee5122 authored by Konstantin Meskhidze's avatar Konstantin Meskhidze Committed by Alex Deucher

drm/amdgpu: Fix logic error

This commit fixes logic error in function 'amdgpu_hw_ip_info':
       - value 'uvd' might be 'vcn'.
Signed-off-by: default avatarKonstantin Meskhidze <konstantin.meskhidze@huawei.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 75818aff
...@@ -431,7 +431,7 @@ static int amdgpu_hw_ip_info(struct amdgpu_device *adev, ...@@ -431,7 +431,7 @@ static int amdgpu_hw_ip_info(struct amdgpu_device *adev,
case AMDGPU_HW_IP_VCN_DEC: case AMDGPU_HW_IP_VCN_DEC:
type = AMD_IP_BLOCK_TYPE_VCN; type = AMD_IP_BLOCK_TYPE_VCN;
for (i = 0; i < adev->vcn.num_vcn_inst; i++) { for (i = 0; i < adev->vcn.num_vcn_inst; i++) {
if (adev->uvd.harvest_config & (1 << i)) if (adev->vcn.harvest_config & (1 << i))
continue; continue;
if (adev->vcn.inst[i].ring_dec.sched.ready) if (adev->vcn.inst[i].ring_dec.sched.ready)
...@@ -443,7 +443,7 @@ static int amdgpu_hw_ip_info(struct amdgpu_device *adev, ...@@ -443,7 +443,7 @@ static int amdgpu_hw_ip_info(struct amdgpu_device *adev,
case AMDGPU_HW_IP_VCN_ENC: case AMDGPU_HW_IP_VCN_ENC:
type = AMD_IP_BLOCK_TYPE_VCN; type = AMD_IP_BLOCK_TYPE_VCN;
for (i = 0; i < adev->vcn.num_vcn_inst; i++) { for (i = 0; i < adev->vcn.num_vcn_inst; i++) {
if (adev->uvd.harvest_config & (1 << i)) if (adev->vcn.harvest_config & (1 << i))
continue; continue;
for (j = 0; j < adev->vcn.num_enc_rings; j++) for (j = 0; j < adev->vcn.num_enc_rings; j++)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment