OSDN Git Service

drm/amdkfd: Only apply TLB flush optimization on ALdebaran
authorEric Huang <jinhuieric.huang@amd.com>
Wed, 30 Jun 2021 21:58:12 +0000 (17:58 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 8 Jul 2021 19:12:26 +0000 (15:12 -0400)
It is based on reverting two patches back.
  drm/amdkfd: Make TLB flush conditional on mapping
  drm/amdgpu: Add table_freed parameter to amdgpu_vm_bo_update

Signed-off-by: Eric Huang <jinhuieric.huang@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c

index da02bd1..3e487e1 100644 (file)
@@ -1721,6 +1721,12 @@ int amdgpu_amdkfd_gpuvm_map_memory_to_gpu(
                                true);
        ret = unreserve_bo_and_vms(&ctx, false, false);
 
+       /* Only apply no TLB flush on Aldebaran to
+        * workaround regressions on other Asics.
+        */
+       if (table_freed && (adev->asic_type != CHIP_ALDEBARAN))
+               *table_freed = true;
+
        goto out;
 
 out_unreserve: