]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdkfd: fix cp hang in eviction
authorEric Huang <JinhuiEric.Huang@amd.com>
Tue, 9 Jul 2019 19:33:53 +0000 (15:33 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 11 Jul 2019 19:37:24 +0000 (14:37 -0500)
commitbe613e59bc84816d4e6652b2fa98067f56316c50
treeaba0381400e3b31c1b7d2c73fab6d376e38810c2
parente672c9e55e2223b6520cdfe42e80f63c469de069
drm/amdkfd: fix cp hang in eviction

The cp hang occurs in OCL conformance test only on supermicro
platform which has 40 cores and the test generates 40 threads.
The root cause is race condition in non-protected flags.

The fix is to add flags of is_evicted and is_active(init_mqd())
into protected area.

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/amdkfd/kfd_device_queue_manager.c