amdgpu: fix segfault when resources are NULL
Signed-off-by: monk.liu <monk.liu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com>main
parent
c68d58aa14
commit
3b50db9d9f
|
@ -659,6 +659,7 @@ static int amdgpu_cs_submit_one(amdgpu_context_handle context,
|
|||
memset(&cs, 0, sizeof(cs));
|
||||
cs.in.chunks = (uint64_t)(uintptr_t)chunk_array;
|
||||
cs.in.ctx_id = context->id;
|
||||
if (ibs_request->resources)
|
||||
cs.in.bo_list_handle = ibs_request->resources->handle;
|
||||
cs.in.num_chunks = ibs_request->number_of_ibs;
|
||||
/* IB chunks */
|
||||
|
|
Loading…
Reference in New Issue