From: Oded Gabbay Date: Wed, 29 Jul 2015 07:33:06 +0000 (+0300) Subject: drm/amdgpu: fix bug when amdkfd destroys hqd X-Git-Tag: v4.3-rc1~75^2~30^2~1 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=e8a64b20eb27cd9c9403f51e4e6c415f9e096e39;p=karo-tx-linux.git drm/amdgpu: fix bug when amdkfd destroys hqd The wrong define was used to check if the hqd is still active v2: Don't use SHIFT as the MASK is already shifted Signed-off-by: Oded Gabbay Reviewed-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c index 2daad335b809..dd2037bc0b4a 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c @@ -450,7 +450,7 @@ static int kgd_hqd_destroy(struct kgd_dev *kgd, uint32_t reset_type, while (true) { temp = RREG32(mmCP_HQD_ACTIVE); - if (temp & CP_HQD_ACTIVE__ACTIVE__SHIFT) + if (temp & CP_HQD_ACTIVE__ACTIVE_MASK) break; if (timeout == 0) { pr_err("kfd: cp queue preemption time out (%dms)\n",