diff options
author | Lucas Stach <l.stach@pengutronix.de> | 2017-12-06 11:49:39 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2017-12-07 11:51:56 -0500 |
commit | 1b1f42d8fde4fef1ed7873bf5aa91755f8c3de35 (patch) | |
tree | 3039b957f8ef645419b5649d28dc7ece3e9ceecd /drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | |
parent | 9ce6aae12c66adf87b5861f8fa5705ea11d0b6ee (diff) |
drm: move amd_gpu_scheduler into common location
This moves and renames the AMDGPU scheduler to a common location in DRM
in order to facilitate re-use by other drivers. This is mostly a straight
forward rename with no code changes.
One notable exception is the function to_drm_sched_fence(), which is no
longer a inline header function to avoid the need to export the
drm_sched_fence_ops_scheduled and drm_sched_fence_ops_finished structures.
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Tested-by: Dieter Nützel <Dieter@nuetzel-hh.de>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c index 4cea9ab237ac..44523a88ebb2 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | |||
@@ -1150,7 +1150,7 @@ static int amdgpu_cs_submit(struct amdgpu_cs_parser *p, | |||
1150 | union drm_amdgpu_cs *cs) | 1150 | union drm_amdgpu_cs *cs) |
1151 | { | 1151 | { |
1152 | struct amdgpu_ring *ring = p->job->ring; | 1152 | struct amdgpu_ring *ring = p->job->ring; |
1153 | struct amd_sched_entity *entity = &p->ctx->rings[ring->idx].entity; | 1153 | struct drm_sched_entity *entity = &p->ctx->rings[ring->idx].entity; |
1154 | struct amdgpu_job *job; | 1154 | struct amdgpu_job *job; |
1155 | unsigned i; | 1155 | unsigned i; |
1156 | uint64_t seq; | 1156 | uint64_t seq; |
@@ -1173,7 +1173,7 @@ static int amdgpu_cs_submit(struct amdgpu_cs_parser *p, | |||
1173 | job = p->job; | 1173 | job = p->job; |
1174 | p->job = NULL; | 1174 | p->job = NULL; |
1175 | 1175 | ||
1176 | r = amd_sched_job_init(&job->base, &ring->sched, entity, p->filp); | 1176 | r = drm_sched_job_init(&job->base, &ring->sched, entity, p->filp); |
1177 | if (r) { | 1177 | if (r) { |
1178 | amdgpu_job_free(job); | 1178 | amdgpu_job_free(job); |
1179 | amdgpu_mn_unlock(p->mn); | 1179 | amdgpu_mn_unlock(p->mn); |
@@ -1202,7 +1202,7 @@ static int amdgpu_cs_submit(struct amdgpu_cs_parser *p, | |||
1202 | amdgpu_ring_priority_get(job->ring, job->base.s_priority); | 1202 | amdgpu_ring_priority_get(job->ring, job->base.s_priority); |
1203 | 1203 | ||
1204 | trace_amdgpu_cs_ioctl(job); | 1204 | trace_amdgpu_cs_ioctl(job); |
1205 | amd_sched_entity_push_job(&job->base, entity); | 1205 | drm_sched_entity_push_job(&job->base, entity); |
1206 | 1206 | ||
1207 | ttm_eu_fence_buffer_objects(&p->ticket, &p->validated, p->fence); | 1207 | ttm_eu_fence_buffer_objects(&p->ticket, &p->validated, p->fence); |
1208 | amdgpu_mn_unlock(p->mn); | 1208 | amdgpu_mn_unlock(p->mn); |