summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTimothy Pearson <tpearson@raptorengineering.com>2018-06-23 19:00:58 -0500
committerTimothy Pearson <tpearson@raptorengineering.com>2018-06-23 19:02:20 -0500
commit461333cedd470140eb1e1667608da2a6d65a58e5 (patch)
treeed9b74661fccdef52f67d285b8081a41ed6bb2e6
parent4c396ffb1f22d50e21517c43f75fcc680f0503a9 (diff)
downloadop-kernel-dev-raptor-dma-dev-4.18-pre.zip
op-kernel-dev-raptor-dma-dev-4.18-pre.tar.gz
Increase AMDGPU_MAX_UVD_INSTANCES to 3polaris-working-raptor-devraptor-dma-dev-4.18-pre
amdgpu_fence_driver_start_ring() attempts to access UVD instance 2 during setup, while the existing UVD instance count only allows instances 0 and 1. Increase AMDGPU_MAX_UVD_INSTANCES by one to avoid the invalid array access. Caught by UBSAN. Signed-off-by: Timothy Pearson <tpearson@raptorengineering.com>
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.h
index 8b23a1b..4a47cb5 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.h
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.h
@@ -31,7 +31,7 @@
#define AMDGPU_UVD_SESSION_SIZE (50*1024)
#define AMDGPU_UVD_FIRMWARE_OFFSET 256
-#define AMDGPU_MAX_UVD_INSTANCES 2
+#define AMDGPU_MAX_UVD_INSTANCES 3
#define AMDGPU_UVD_FIRMWARE_SIZE(adev) \
(AMDGPU_GPU_PAGE_ALIGN(le32_to_cpu(((const struct common_firmware_header *)(adev)->uvd.fw->data)->ucode_size_bytes) + \
OpenPOWER on IntegriCloud