diff options
author | Christian König <christian.koenig@amd.com> | 2016-01-31 06:29:04 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2016-02-10 14:17:20 -0500 |
commit | b07c60c0652c497af0c42c1278941f7c5a187fe9 (patch) | |
tree | d19e6dfc68fe4b25032c19ceae0e5be0f7e9c25d /drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c | |
parent | 9e5d53094c5366a9a14e0694e45e794902cc2c04 (diff) |
drm/amdgpu: move ring from IBs into job
We can't submit to multiple rings at the same time anyway.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Alex Deucher <alexander.deucer@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c index 10d098e33707..84453c1c4b07 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_sched.c | |||
@@ -70,7 +70,7 @@ static struct fence *amdgpu_sched_dependency(struct amd_sched_job *sched_job) | |||
70 | struct fence *fence = amdgpu_sync_get_fence(sync); | 70 | struct fence *fence = amdgpu_sync_get_fence(sync); |
71 | 71 | ||
72 | if (fence == NULL && vm && !job->ibs->grabbed_vmid) { | 72 | if (fence == NULL && vm && !job->ibs->grabbed_vmid) { |
73 | struct amdgpu_ring *ring = job->ibs->ring; | 73 | struct amdgpu_ring *ring = job->ring; |
74 | int r; | 74 | int r; |
75 | 75 | ||
76 | r = amdgpu_vm_grab_id(vm, ring, sync, | 76 | r = amdgpu_vm_grab_id(vm, ring, sync, |
@@ -98,7 +98,7 @@ static struct fence *amdgpu_sched_run_job(struct amd_sched_job *sched_job) | |||
98 | } | 98 | } |
99 | job = to_amdgpu_job(sched_job); | 99 | job = to_amdgpu_job(sched_job); |
100 | trace_amdgpu_sched_run_job(job); | 100 | trace_amdgpu_sched_run_job(job); |
101 | r = amdgpu_ib_schedule(job->adev, job->num_ibs, job->ibs, job->owner); | 101 | r = amdgpu_ib_schedule(job->ring, job->num_ibs, job->ibs, job->owner); |
102 | if (r) { | 102 | if (r) { |
103 | DRM_ERROR("Error scheduling IBs (%d)\n", r); | 103 | DRM_ERROR("Error scheduling IBs (%d)\n", r); |
104 | goto err; | 104 | goto err; |
@@ -142,6 +142,7 @@ int amdgpu_sched_ib_submit_kernel_helper(struct amdgpu_device *adev, | |||
142 | *f = fence_get(&job->base.s_fence->base); | 142 | *f = fence_get(&job->base.s_fence->base); |
143 | 143 | ||
144 | job->adev = adev; | 144 | job->adev = adev; |
145 | job->ring = ring; | ||
145 | job->ibs = ibs; | 146 | job->ibs = ibs; |
146 | job->num_ibs = num_ibs; | 147 | job->num_ibs = num_ibs; |
147 | job->owner = owner; | 148 | job->owner = owner; |