drm/amdgpu: reset psp ring wptr during ring_create
authorYuBiao Wang <YuBiao.Wang@amd.com>
Wed, 9 Jun 2021 02:41:34 +0000 (10:41 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 11 Jun 2021 20:03:26 +0000 (16:03 -0400)
commit29b4ac0ed9130229cf518edab01fd6b20d9f1c92
treed2567ff439d937fc023b694d28e6d2598acc980e
parent076f55a45e9e41fcbc377ad064f10f29b26dc298
drm/amdgpu: reset psp ring wptr during ring_create

[Why]
psp ring wptr is not initialized properly in ring_create,
which would lead to psp failure after several gpu reset.

[How]
Set ring_wptr to zero in psp_ring_create.

Signed-off-by: YuBiao Wang <YuBiao.Wang@amd.com>
Reviewed-by: Horace Chen <horace.chen@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/psp_v11_0.c
drivers/gpu/drm/amd/amdgpu/psp_v3_1.c