summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/radeon/radeon_vce_50.c
diff options
context:
space:
mode:
authorLeo Liu <leo.liu@amd.com>2015-06-01 13:48:24 -0400
committerMarek Olšák <marek.olsak@amd.com>2015-08-14 15:02:30 +0200
commit57fabe9f3a21a2a370284575833637d37e987cb5 (patch)
tree61d5ba18568427336ac895b4b70f6b2e08c2f6a1 /src/gallium/drivers/radeon/radeon_vce_50.c
parente91a67abfa5112acd481ee4a3f07c03f6ff2708c (diff)
downloadexternal_mesa3d-57fabe9f3a21a2a370284575833637d37e987cb5.zip
external_mesa3d-57fabe9f3a21a2a370284575833637d37e987cb5.tar.gz
external_mesa3d-57fabe9f3a21a2a370284575833637d37e987cb5.tar.bz2
radeon/vce: add config task and put task info into encoder v2
The config task has own task ID, extract the configuration functions into config task. v2 (chk): calculate offset automatically Signed-off-by: Leo Liu <leo.liu@amd.com> Signed-off-by: Christian König <christian.koenig@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'src/gallium/drivers/radeon/radeon_vce_50.c')
-rw-r--r--src/gallium/drivers/radeon/radeon_vce_50.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/src/gallium/drivers/radeon/radeon_vce_50.c b/src/gallium/drivers/radeon/radeon_vce_50.c
index a11cc6a..377e154 100644
--- a/src/gallium/drivers/radeon/radeon_vce_50.c
+++ b/src/gallium/drivers/radeon/radeon_vce_50.c
@@ -44,18 +44,6 @@
#include "radeon_video.h"
#include "radeon_vce.h"
-static void task_info(struct rvce_encoder *enc, uint32_t taskOperation)
-{
- RVCE_BEGIN(0x00000002); // task info
- RVCE_CS(0xffffffff); // offsetOfNextTaskInfo
- RVCE_CS(taskOperation); // taskOperation
- RVCE_CS(0x00000000); // referencePictureDependency
- RVCE_CS(0x00000000); // collocateFlagDependency
- RVCE_CS(0x00000000); // feedbackIndex
- RVCE_CS(0x00000000); // videoBitstreamRingIndex
- RVCE_END();
-}
-
static void rate_control(struct rvce_encoder *enc)
{
RVCE_BEGIN(0x04000005); // rate control
@@ -93,7 +81,7 @@ static void encode(struct rvce_encoder *enc)
int i;
unsigned luma_offset, chroma_offset;
- task_info(enc, 0x00000003);
+ enc->task_info(enc, 0x00000003, 0, 0, 0);
RVCE_BEGIN(0x05000001); // context buffer
RVCE_READWRITE(enc->cpb.res->cs_buf, enc->cpb.res->domains, 0); // encodeContextAddressHi/Lo