diff options
author | Monk Liu <Monk.Liu@amd.com> | 2016-03-16 22:47:07 -0400 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2016-03-17 11:53:34 -0400 |
commit | cc55c45db5e2c97445d4663d45348a0fc27bf9ad (patch) | |
tree | 26c515f01560ece32c978c9a5bf2a0a4af27c1d4 /drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | |
parent | 16a8a49be1b878ef6dd5d1663d456e254e54ae3d (diff) |
drm/amdgpu: give a fence param to ib_free
thus amdgpu_ib_free() can hook sched fence to SA manager
in later patches.
BTW:
for amdgpu_free_job(), it should only fence_put() the
fence of the last ib once, so fix it as well in this patch.
Signed-off-by: Monk Liu <Monk.Liu@amd.com>
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_job.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_job.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_job.c index 692b45560d0a..df2f66666f85 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_job.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | |||
@@ -72,7 +72,8 @@ void amdgpu_job_free(struct amdgpu_job *job) | |||
72 | unsigned i; | 72 | unsigned i; |
73 | 73 | ||
74 | for (i = 0; i < job->num_ibs; ++i) | 74 | for (i = 0; i < job->num_ibs; ++i) |
75 | amdgpu_ib_free(job->adev, &job->ibs[i]); | 75 | amdgpu_sa_bo_free(job->adev, &job->ibs[i].sa_bo, job->ibs[job->num_ibs - 1].fence); |
76 | fence_put(job->ibs[job->num_ibs - 1].fence); | ||
76 | 77 | ||
77 | amdgpu_bo_unref(&job->uf.bo); | 78 | amdgpu_bo_unref(&job->uf.bo); |
78 | amdgpu_sync_free(&job->sync); | 79 | amdgpu_sync_free(&job->sync); |