diff options
author | Ben Goz <ben.goz@amd.com> | 2015-01-15 17:14:47 +0200 |
---|---|---|
committer | Oded Gabbay <oded.gabbay@amd.com> | 2015-01-15 17:14:47 +0200 |
commit | f046bfdf735794d5893963427eb54302b7940a86 (patch) | |
tree | c224cdbc519c14c7988501f6a18c1f53c860ed01 /drivers/gpu/drm | |
parent | 26bc420b59a38e4e6685a73345a0def461136dce (diff) | |
download | linux-f046bfdf735794d5893963427eb54302b7940a86.tar.bz2 |
drm/amdkfd: PQM handle queue creation fault
If the first queue created was failed on DQM then PQM should
unregister the process from DQM.
Signed-off-by: Ben Goz <ben.goz@amd.com>
Signed-off-by: Oded Gabbay <oded.gabbay@amd.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r-- | drivers/gpu/drm/amd/amdkfd/kfd_process_queue_manager.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_process_queue_manager.c b/drivers/gpu/drm/amd/amdkfd/kfd_process_queue_manager.c index 47526780d736..326d26881afd 100644 --- a/drivers/gpu/drm/amd/amdkfd/kfd_process_queue_manager.c +++ b/drivers/gpu/drm/amd/amdkfd/kfd_process_queue_manager.c @@ -241,7 +241,10 @@ int pqm_create_queue(struct process_queue_manager *pqm, err_create_queue: kfree(pqn); err_allocate_pqn: + /* check if queues list is empty unregister process from device */ clear_bit(*qid, pqm->queue_slot_bitmap); + if (list_empty(&pqm->queues)) + dev->dqm->unregister_process(dev->dqm, &pdd->qpd); return retval; } |