提交 afe10081 编写于 作者: C Chunming Zhou 提交者: Alex Deucher

drm/amdgpu: add check for callback

it is possible that the callback isn't defined sometimes.
Signed-off-by: NChunming Zhou <david1.zhou@amd.com>
Reviewed-by: NChristian K?nig <christian.koenig@amd.com>
上级 02b9f0bf
......@@ -137,7 +137,8 @@ static void amdgpu_job_work_func(struct work_struct *work)
container_of(work, struct amdgpu_cs_parser,
job_work);
mutex_lock(&sched_job->job_lock);
sched_job->free_job(sched_job);
if (sched_job->free_job)
sched_job->free_job(sched_job);
mutex_unlock(&sched_job->job_lock);
/* after processing job, free memory */
kfree(sched_job);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册