Skip to content

Commit eabc716

Browse files
Timur Kristófalexdeucher
authored andcommitted
drm/amdgpu/vce1: Enable VCE1 on Tahiti, Pitcairn, Cape Verde GPUs
Add the VCE1 IP block to the SI GPUs that have it. Advertise the encoder capabilities corresponding to VCE1, so the userspace applications can detect and use it. Signed-off-by: Timur Kristóf <timur.kristof@gmail.com> Co-developed-by: Alexandre Demers <alexandre.f.demers@gmail.com> Signed-off-by: Alexandre Demers <alexandre.f.demers@gmail.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
1 parent 53cc70f commit eabc716

1 file changed

Lines changed: 3 additions & 11 deletions

File tree

  • drivers/gpu/drm/amd/amdgpu

drivers/gpu/drm/amd/amdgpu/si.c

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@
4545
#include "dce_v6_0.h"
4646
#include "si.h"
4747
#include "uvd_v3_1.h"
48+
#include "vce_v1_0.h"
4849

4950
#include "uvd/uvd_4_0_d.h"
5051

@@ -921,8 +922,6 @@ static const u32 hainan_mgcg_cgcg_init[] =
921922
0x3630, 0xfffffff0, 0x00000100,
922923
};
923924

924-
/* XXX: update when we support VCE */
925-
#if 0
926925
/* tahiti, pitcairn, verde */
927926
static const struct amdgpu_video_codec_info tahiti_video_codecs_encode_array[] =
928927
{
@@ -940,13 +939,7 @@ static const struct amdgpu_video_codecs tahiti_video_codecs_encode =
940939
.codec_count = ARRAY_SIZE(tahiti_video_codecs_encode_array),
941940
.codec_array = tahiti_video_codecs_encode_array,
942941
};
943-
#else
944-
static const struct amdgpu_video_codecs tahiti_video_codecs_encode =
945-
{
946-
.codec_count = 0,
947-
.codec_array = NULL,
948-
};
949-
#endif
942+
950943
/* oland and hainan don't support encode */
951944
static const struct amdgpu_video_codecs hainan_video_codecs_encode =
952945
{
@@ -2717,7 +2710,7 @@ int si_set_ip_blocks(struct amdgpu_device *adev)
27172710
else
27182711
amdgpu_device_ip_block_add(adev, &dce_v6_0_ip_block);
27192712
amdgpu_device_ip_block_add(adev, &uvd_v3_1_ip_block);
2720-
/* amdgpu_device_ip_block_add(adev, &vce_v1_0_ip_block); */
2713+
amdgpu_device_ip_block_add(adev, &vce_v1_0_ip_block);
27212714
break;
27222715
case CHIP_OLAND:
27232716
amdgpu_device_ip_block_add(adev, &si_common_ip_block);
@@ -2735,7 +2728,6 @@ int si_set_ip_blocks(struct amdgpu_device *adev)
27352728
else
27362729
amdgpu_device_ip_block_add(adev, &dce_v6_4_ip_block);
27372730
amdgpu_device_ip_block_add(adev, &uvd_v3_1_ip_block);
2738-
/* amdgpu_device_ip_block_add(adev, &vce_v1_0_ip_block); */
27392731
break;
27402732
case CHIP_HAINAN:
27412733
amdgpu_device_ip_block_add(adev, &si_common_ip_block);

0 commit comments

Comments
 (0)