]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amd/amdgpu: Fix incorrect logic to increment VCN doorbell index
authorBokun Zhang <Bokun.Zhang@amd.com>
Mon, 9 Nov 2020 18:59:27 +0000 (13:59 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 10 Nov 2020 19:26:24 +0000 (14:26 -0500)
commite465856dfbeaad0f769df3e8aea5749c4e6f83ae
tree9ffbfb9384bb38e77e9b770472b00c37d7891f2c
parentf859e10c1acc7bb1e3e6fb136c8e33f52f087fc0
drm/amd/amdgpu: Fix incorrect logic to increment VCN doorbell index

- The original logic uses a counter based index assignment,
  which is incorrect if we only assign VCN1 to this VF but no VCN0

  The doorbell index is absolute, so we can calculate it by
  using index variable i and j

Signed-off-by: Bokun Zhang <Bokun.Zhang@amd.com>
Reviewed-by: Monk Liu <monk.liu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c