forked from Minki/linux
drm/amdkfd: Compress unnecessary function parameters
Signed-off-by: Yong Zhao <yong.zhao@amd.com> Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com> Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
This commit is contained in:
parent
9fd3f1bfae
commit
e6f791b1b0
@ -282,8 +282,7 @@ static int kfd_ioctl_create_queue(struct file *filep, struct kfd_process *p,
|
||||
p->pasid,
|
||||
dev->id);
|
||||
|
||||
err = pqm_create_queue(&p->pqm, dev, filep, &q_properties,
|
||||
0, q_properties.type, &queue_id);
|
||||
err = pqm_create_queue(&p->pqm, dev, filep, &q_properties, &queue_id);
|
||||
if (err != 0)
|
||||
goto err_create_queue;
|
||||
|
||||
|
@ -184,9 +184,10 @@ static int dbgdev_register_diq(struct kfd_dbgdev *dbgdev)
|
||||
struct kernel_queue *kq = NULL;
|
||||
int status;
|
||||
|
||||
properties.type = KFD_QUEUE_TYPE_DIQ;
|
||||
|
||||
status = pqm_create_queue(dbgdev->pqm, dbgdev->dev, NULL,
|
||||
&properties, 0, KFD_QUEUE_TYPE_DIQ,
|
||||
&qid);
|
||||
&properties, &qid);
|
||||
|
||||
if (status) {
|
||||
pr_err("Failed to create DIQ\n");
|
||||
|
@ -677,8 +677,6 @@ int pqm_create_queue(struct process_queue_manager *pqm,
|
||||
struct kfd_dev *dev,
|
||||
struct file *f,
|
||||
struct queue_properties *properties,
|
||||
unsigned int flags,
|
||||
enum kfd_queue_type type,
|
||||
unsigned int *qid);
|
||||
int pqm_destroy_queue(struct process_queue_manager *pqm, unsigned int qid);
|
||||
int pqm_update_queue(struct process_queue_manager *pqm, unsigned int qid,
|
||||
|
@ -142,20 +142,17 @@ int pqm_create_queue(struct process_queue_manager *pqm,
|
||||
struct kfd_dev *dev,
|
||||
struct file *f,
|
||||
struct queue_properties *properties,
|
||||
unsigned int flags,
|
||||
enum kfd_queue_type type,
|
||||
unsigned int *qid)
|
||||
{
|
||||
int retval;
|
||||
struct kfd_process_device *pdd;
|
||||
struct queue_properties q_properties;
|
||||
struct queue *q;
|
||||
struct process_queue_node *pqn;
|
||||
struct kernel_queue *kq;
|
||||
int num_queues = 0;
|
||||
struct queue *cur;
|
||||
enum kfd_queue_type type = properties->type;
|
||||
|
||||
memcpy(&q_properties, properties, sizeof(struct queue_properties));
|
||||
q = NULL;
|
||||
kq = NULL;
|
||||
|
||||
@ -206,7 +203,7 @@ int pqm_create_queue(struct process_queue_manager *pqm,
|
||||
goto err_create_queue;
|
||||
}
|
||||
|
||||
retval = create_cp_queue(pqm, dev, &q, &q_properties, f, *qid);
|
||||
retval = create_cp_queue(pqm, dev, &q, properties, f, *qid);
|
||||
if (retval != 0)
|
||||
goto err_create_queue;
|
||||
pqn->q = q;
|
||||
@ -243,9 +240,8 @@ int pqm_create_queue(struct process_queue_manager *pqm,
|
||||
list_add(&pqn->process_queue_list, &pqm->queues);
|
||||
|
||||
if (q) {
|
||||
*properties = q->properties;
|
||||
pr_debug("PQM done creating queue\n");
|
||||
print_queue_properties(properties);
|
||||
print_queue_properties(&q->properties);
|
||||
}
|
||||
|
||||
return retval;
|
||||
|
Loading…
Reference in New Issue
Block a user