drm/amdkfd: make reset wavefronts per process per device

This commit moves the reset wavefront flag to per process per device
data structure, so we can support multiple devices.

Signed-off-by: Ben Goz <ben.goz@amd.com>
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
This commit is contained in:
Ben Goz
2015-03-25 13:12:20 +02:00
committed by Oded Gabbay
parent 6235e15ea6
commit a82918f18a
3 changed files with 25 additions and 13 deletions

View File

@@ -946,7 +946,7 @@ static int destroy_queues_cpsch(struct device_queue_manager *dqm,
{
int retval;
enum kfd_preempt_type_filter preempt_type;
struct kfd_process *p;
struct kfd_process_device *pdd;
BUG_ON(!dqm);
@@ -981,8 +981,9 @@ static int destroy_queues_cpsch(struct device_queue_manager *dqm,
retval = amdkfd_fence_wait_timeout(dqm->fence_addr, KFD_FENCE_COMPLETED,
QUEUE_PREEMPT_DEFAULT_TIMEOUT_MS);
if (retval != 0) {
p = kfd_get_process(current);
p->reset_wavefronts = true;
pdd = kfd_get_process_device_data(dqm->dev,
kfd_get_process(current));
pdd->reset_wavefronts = true;
goto out;
}
pm_release_ib(&dqm->packets);