Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/amdgpu: set the VM pointer to NULL in amdgpu_job_prepare

As soon as the prepare phase is completed the VM might be released,
better set it to NULL.

Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Christian König and committed by
Alex Deucher
26c95e83 57f812d1

+7
+7
drivers/gpu/drm/amd/amdgpu/amdgpu_job.c
··· 361 361 dev_err(ring->adev->dev, "Error getting VM ID (%d)\n", r); 362 362 goto error; 363 363 } 364 + /* 365 + * The VM structure might be released after the VMID is 366 + * assigned, we had multiple problems with people trying to use 367 + * the VM pointer so better set it to NULL. 368 + */ 369 + if (!fence) 370 + job->vm = NULL; 364 371 } 365 372 366 373 return fence;