[Public]

Acked-by: Alex Deucher <alexander.deuc...@amd.com>
________________________________
From: amd-gfx <amd-gfx-boun...@lists.freedesktop.org> on behalf of Jane Jian 
<jane.j...@amd.com>
Sent: Tuesday, June 11, 2024 6:06 AM
To: Chen, JingWen (Wayne) <jingwen.ch...@amd.com>
Cc: amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org>; Jian, Jane 
<jane.j...@amd.com>
Subject: [PATCH] drm/amdgpu/vcn: port mmsch ctx table size fix from jpeg v4

add jpeg table size to ctx table size rather than override it

Signed-off-by: Jane Jian <jane.j...@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c 
b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c
index 04d8966423de..0edfb7754768 100644
--- a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c
+++ b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c
@@ -202,7 +202,7 @@ static int jpeg_v4_0_3_start_sriov(struct amdgpu_device 
*adev)

                 memset(&header, 0, sizeof(struct mmsch_v4_0_3_init_header));
                 header.version = MMSCH_VERSION;
-               header.total_size = sizeof(struct mmsch_v4_0_3_init_header) >> 
2;
+               header.total_size = RREG32_SOC15(VCN, 0, regMMSCH_VF_CTX_SIZE);

                 table_loc = (uint32_t *)table->cpu_addr;
                 table_loc += header.total_size;
--
2.34.1

Reply via email to