drm/amdgpu/discovery: add VCN 4.0 Support
authorJames Zhu <James.Zhu@amd.com>
Mon, 4 Apr 2022 21:35:39 +0000 (17:35 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 4 May 2022 14:43:56 +0000 (10:43 -0400)
Enable VCN 4.0 on asics where it is present.

Signed-off-by: James Zhu <James.Zhu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c

index aa5f31ad8bc7d351ffee74d45ca806d26a217360..0e0382a82b223262df861247e6e4d826f99b055c 100644 (file)
@@ -68,6 +68,8 @@
 #include "jpeg_v2_0.h"
 #include "vcn_v3_0.h"
 #include "jpeg_v3_0.h"
+#include "vcn_v4_0.h"
+#include "jpeg_v4_0.h"
 #include "amdgpu_vkms.h"
 #include "mes_v10_1.h"
 #include "mes_v11_0.h"
@@ -1853,6 +1855,10 @@ static int amdgpu_discovery_set_mm_ip_blocks(struct amdgpu_device *adev)
                case IP_VERSION(3, 0, 33):
                        amdgpu_device_ip_block_add(adev, &vcn_v3_0_ip_block);
                        break;
+               case IP_VERSION(4, 0, 0):
+                       amdgpu_device_ip_block_add(adev, &vcn_v4_0_ip_block);
+                       amdgpu_device_ip_block_add(adev, &jpeg_v4_0_ip_block);
+                       break;
                default:
                        dev_err(adev->dev,
                                "Failed to add vcn/jpeg ip block(UVD_HWIP:0x%x)\n",