Commit feb36dd0 authored by Le Ma's avatar Le Ma Committed by Alex Deucher
Browse files

drm/amdgpu: convert the doorbell_index to 2 dwords offset for kiq



KIQ doorbell_index is non-zero from XCC1, thus need to left-shift it like
other rings.

Signed-off-by: default avatarLe Ma <le.ma@amd.com>
Acked-by: default avatarFelix Kuehling <Felix.Kuehling@amd.com>
Reviewed-by: default avatarLijo Lazar <lijo.lazar@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 5de6bd6a
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -313,14 +313,13 @@ int amdgpu_gfx_kiq_init_ring(struct amdgpu_device *adev,
	ring->adev = NULL;
	ring->ring_obj = NULL;
	ring->use_doorbell = true;
	ring->doorbell_index = adev->doorbell_index.kiq;
	ring->xcc_id = xcc_id;
	ring->vm_hub = AMDGPU_GFXHUB(xcc_id);
	if (xcc_id >= 1)
		ring->doorbell_index = adev->doorbell_index.xcc1_kiq_start +
					xcc_id - 1;
		ring->doorbell_index = (adev->doorbell_index.xcc1_kiq_start +
					xcc_id - 1) << 1;
	else
		ring->doorbell_index = adev->doorbell_index.kiq;
		ring->doorbell_index = adev->doorbell_index.kiq << 1;

	r = amdgpu_gfx_kiq_acquire(adev, ring, xcc_id);
	if (r)