aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu.h
diff options
context:
space:
mode:
authorArindam Nath <arindam.nath@amd.com>2016-04-12 07:46:15 -0400
committerAlex Deucher <alexander.deucher@amd.com>2016-05-04 20:20:23 -0400
commitc036554170fcc2238c32a7edd72c1b61b886428a (patch)
tree2832729c8191be1a811c08b8d17d011dd437be31 /drivers/gpu/drm/amd/amdgpu/amdgpu.h
parentaeba709a15ad66d3f8a2b38bada9f643ebe3dc04 (diff)
drm/amdgpu: handle more than 10 UVD sessions (v2)
Change History -------------- v2: - Make firmware version check correctly. Firmware versions >= 1.80 should all support 40 UVD instances. - Replace AMDGPU_MAX_UVD_HANDLES with max_handles variable. v1: - The firmware can handle upto 40 UVD sessions. Signed-off-by: Arindam Nath <arindam.nath@amd.com> Signed-off-by: Ayyappa Chandolu <ayyappa.chandolu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu.h')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
index d1ad7634f351..c9fe2d56cebf 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu.h
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
@@ -1593,16 +1593,19 @@ void amdgpu_get_pcie_info(struct amdgpu_device *adev);
1593/* 1593/*
1594 * UVD 1594 * UVD
1595 */ 1595 */
1596#define AMDGPU_MAX_UVD_HANDLES 10 1596#define AMDGPU_DEFAULT_UVD_HANDLES 10
1597#define AMDGPU_UVD_STACK_SIZE (1024*1024) 1597#define AMDGPU_MAX_UVD_HANDLES 40
1598#define AMDGPU_UVD_HEAP_SIZE (1024*1024) 1598#define AMDGPU_UVD_STACK_SIZE (200*1024)
1599#define AMDGPU_UVD_FIRMWARE_OFFSET 256 1599#define AMDGPU_UVD_HEAP_SIZE (256*1024)
1600#define AMDGPU_UVD_SESSION_SIZE (50*1024)
1601#define AMDGPU_UVD_FIRMWARE_OFFSET 256
1600 1602
1601struct amdgpu_uvd { 1603struct amdgpu_uvd {
1602 struct amdgpu_bo *vcpu_bo; 1604 struct amdgpu_bo *vcpu_bo;
1603 void *cpu_addr; 1605 void *cpu_addr;
1604 uint64_t gpu_addr; 1606 uint64_t gpu_addr;
1605 void *saved_bo; 1607 void *saved_bo;
1608 unsigned max_handles;
1606 atomic_t handles[AMDGPU_MAX_UVD_HANDLES]; 1609 atomic_t handles[AMDGPU_MAX_UVD_HANDLES];
1607 struct drm_file *filp[AMDGPU_MAX_UVD_HANDLES]; 1610 struct drm_file *filp[AMDGPU_MAX_UVD_HANDLES];
1608 struct delayed_work idle_work; 1611 struct delayed_work idle_work;