summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c
diff options
context:
space:
mode:
authorJunwei Zhang <Jerry.Zhang@amd.com>2015-09-09 04:05:55 +0300
committerAlex Deucher <alexander.deucher@amd.com>2015-09-24 00:23:36 +0300
commit4c7eb91cae88fd2aa101750d6825b4176f85ffb2 (patch)
tree852e67d3ae0e4bad92b8405ea9bf46fae1ac0d47 /drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c
parentbf60efd353f68e5dec1a177b5cbe4da07c819569 (diff)
downloadlinux-4c7eb91cae88fd2aa101750d6825b4176f85ffb2.tar.xz
drm/amdgpu: refine the job naming for amdgpu_job and amdgpu_sched_job
Use consistent naming across functions. Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: David Zhou <david1.zhou@amd.com> Signed-off-by: Junwei Zhang <Jerry.Zhang@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c
index 5724a81fbf5e..af1a3dabd190 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c
@@ -27,42 +27,42 @@
#include <drm/drmP.h>
#include "amdgpu.h"
-static struct fence *amdgpu_sched_dependency(struct amd_sched_job *job)
+static struct fence *amdgpu_sched_dependency(struct amd_sched_job *sched_job)
{
- struct amdgpu_job *sched_job = (struct amdgpu_job *)job;
- return amdgpu_sync_get_fence(&sched_job->ibs->sync);
+ struct amdgpu_job *job = (struct amdgpu_job *)sched_job;
+ return amdgpu_sync_get_fence(&job->ibs->sync);
}
-static struct fence *amdgpu_sched_run_job(struct amd_sched_job *job)
+static struct fence *amdgpu_sched_run_job(struct amd_sched_job *sched_job)
{
struct amdgpu_fence *fence = NULL;
- struct amdgpu_job *sched_job;
+ struct amdgpu_job *job;
int r;
- if (!job) {
+ if (!sched_job) {
DRM_ERROR("job is null\n");
return NULL;
}
- sched_job = (struct amdgpu_job *)job;
- mutex_lock(&sched_job->job_lock);
- r = amdgpu_ib_schedule(sched_job->adev,
- sched_job->num_ibs,
- sched_job->ibs,
- sched_job->base.owner);
+ job = (struct amdgpu_job *)sched_job;
+ mutex_lock(&job->job_lock);
+ r = amdgpu_ib_schedule(job->adev,
+ job->num_ibs,
+ job->ibs,
+ job->base.owner);
if (r) {
DRM_ERROR("Error scheduling IBs (%d)\n", r);
goto err;
}
- fence = amdgpu_fence_ref(sched_job->ibs[sched_job->num_ibs - 1].fence);
+ fence = amdgpu_fence_ref(job->ibs[job->num_ibs - 1].fence);
err:
- if (sched_job->free_job)
- sched_job->free_job(sched_job);
+ if (job->free_job)
+ job->free_job(job);
- mutex_unlock(&sched_job->job_lock);
- fence_put(&sched_job->base.s_fence->base);
- kfree(sched_job);
+ mutex_unlock(&job->job_lock);
+ fence_put(&job->base.s_fence->base);
+ kfree(job);
return fence ? &fence->base : NULL;
}