]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdgpu/sdma: Fix incorrect calculations of the wptr of the doorbells
authorHaohui Mai <ricetons@gmail.com>
Mon, 25 Apr 2022 12:41:38 +0000 (20:41 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 26 Apr 2022 15:44:01 +0000 (11:44 -0400)
commitddaae593e5fa6c2a1324d0817794ae41853f0951
tree666617540b9f3fae90b5d1ff2c924e04423f578f
parente701789b444b3cc96293d7f0664f165924b48ea4
drm/amdgpu/sdma: Fix incorrect calculations of the wptr of the doorbells

This patch fixes the issue where the driver miscomputes the 64-bit
values of the wptr of the SDMA doorbell when initializing the
hardware. SDMA engines v4 and later on have full 64-bit registers for
wptr thus they should be set properly.

Older generation hardwares like CIK / SI have only 16 / 20 / 24bits
for the WPTR, where the calls of lower_32_bits() will be removed in a
following patch.

Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Haohui Mai <ricetons@gmail.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c
drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c