summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorLeo Liu <[email protected]>2015-07-13 13:36:27 -0400
committerMarek Olšák <[email protected]>2015-08-14 15:02:31 +0200
commit0654a9ca17c17fe140f70d126c878a0ce4736b76 (patch)
treea7149103b24158da02f6d67fdef4d8b9a6bb667b /src/gallium
parent09def7e1e06827ab1eae091f0e765d91c6715cf9 (diff)
radeon/vce: disable VCE dual instance for harvest part
Signed-off-by: Leo Liu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Christian König <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/drivers/radeon/radeon_vce.c4
-rw-r--r--src/gallium/drivers/radeon/radeon_winsys.h1
-rw-r--r--src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c1
3 files changed, 5 insertions, 1 deletions
diff --git a/src/gallium/drivers/radeon/radeon_vce.c b/src/gallium/drivers/radeon/radeon_vce.c
index bc8f36db355..7eab974a3df 100644
--- a/src/gallium/drivers/radeon/radeon_vce.c
+++ b/src/gallium/drivers/radeon/radeon_vce.c
@@ -408,7 +408,9 @@ struct pipe_video_codec *rvce_create_encoder(struct pipe_context *context,
if (rscreen->info.family >= CHIP_TONGA)
enc->dual_pipe = true;
/* TODO enable B frame with dual instance */
- if ((rscreen->info.family >= CHIP_TONGA) && (templ->max_references == 1))
+ if ((rscreen->info.family >= CHIP_TONGA) &&
+ (templ->max_references == 1) &&
+ (rscreen->info.vce_harvest_config == 0))
enc->dual_inst = true;
enc->base = *templ;
diff --git a/src/gallium/drivers/radeon/radeon_winsys.h b/src/gallium/drivers/radeon/radeon_winsys.h
index d7424eef27e..7ab6e56e099 100644
--- a/src/gallium/drivers/radeon/radeon_winsys.h
+++ b/src/gallium/drivers/radeon/radeon_winsys.h
@@ -244,6 +244,7 @@ struct radeon_info {
boolean cik_macrotile_mode_array_valid;
uint32_t cik_macrotile_mode_array[16];
+ uint32_t vce_harvest_config;
};
enum radeon_feature_id {
diff --git a/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c b/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
index f57f45b618f..012c9003b69 100644
--- a/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
+++ b/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
@@ -164,6 +164,7 @@ static boolean do_winsys_init(struct amdgpu_winsys *ws)
/* Set chip identification. */
ws->info.pci_id = ws->amdinfo.asic_id; /* TODO: is this correct? */
+ ws->info.vce_harvest_config = ws->amdinfo.vce_harvest_config;
switch (ws->info.pci_id) {
#define CHIPSET(pci_id, name, cfamily) case pci_id: ws->info.family = CHIP_##cfamily; break;