diff options
author | Arindam Nath <arindam.nath@amd.com> | 2016-04-06 21:33:51 +0200 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2016-05-05 02:19:35 +0200 |
commit | 7050c6ef5f0e9bc5e6bf9eb035320b70f731b919 (patch) | |
tree | dfa4df5d70b954551999ace972f998ee93371d57 /drivers/gpu/drm/radeon/uvd_v4_2.c | |
parent | drm/amdgpu: reuse VMIDs already assigned to a process (diff) | |
download | linux-7050c6ef5f0e9bc5e6bf9eb035320b70f731b919.tar.xz linux-7050c6ef5f0e9bc5e6bf9eb035320b70f731b919.zip |
drm/radeon: add support for loading new UVD fw
Signed-off-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Arindam Nath <arindam.nath@amd.com>
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/uvd_v4_2.c')
-rw-r--r-- | drivers/gpu/drm/radeon/uvd_v4_2.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/gpu/drm/radeon/uvd_v4_2.c b/drivers/gpu/drm/radeon/uvd_v4_2.c index d04d5073eef2..205562fa31e3 100644 --- a/drivers/gpu/drm/radeon/uvd_v4_2.c +++ b/drivers/gpu/drm/radeon/uvd_v4_2.c @@ -41,7 +41,13 @@ int uvd_v4_2_resume(struct radeon_device *rdev) uint32_t size; /* programm the VCPU memory controller bits 0-27 */ - addr = rdev->uvd.gpu_addr >> 3; + + /* skip over the header of the new firmware format */ + if (rdev->uvd.fw_header_present) + addr = (rdev->uvd.gpu_addr + 0x200) >> 3; + else + addr = rdev->uvd.gpu_addr >> 3; + size = RADEON_GPU_PAGE_ALIGN(rdev->uvd_fw->size + 4) >> 3; WREG32(UVD_VCPU_CACHE_OFFSET0, addr); WREG32(UVD_VCPU_CACHE_SIZE0, size); |