summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_object.h
diff options
context:
space:
mode:
authorSunil Khatri <sunil.khatri@amd.com>2026-05-13 13:29:35 +0530
committerAlex Deucher <alexander.deucher@amd.com>2026-05-19 11:45:42 -0400
commit5c02889ea22575c3bcfdf212e65fac316cbc6c6a (patch)
tree47e201869a7dbe345793de082643b4e39236e78f /drivers/gpu/drm/amd/amdgpu/amdgpu_object.h
parentcc768f4dd0bb9083c813683eeec44fc23921f771 (diff)
downloadlinux-next-5c02889ea22575c3bcfdf212e65fac316cbc6c6a.tar.gz
linux-next-5c02889ea22575c3bcfdf212e65fac316cbc6c6a.zip
drm/amdgpu: userq_va_mapped should remain true once done
Multiple queues needs these bo_va objects belonging to the same uq_mgr. So once they are mapped lets not unmap them as at any point of time any of the queues might be using it. Also userq_va_mapped should be a boolean than atomic. Signed-off-by: Sunil Khatri <sunil.khatri@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_object.h')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_object.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.h
index 912c9afaf9e1..4d68732d6223 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.h
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.h
@@ -96,7 +96,8 @@ struct amdgpu_bo_va {
* if non-zero, cannot unmap from GPU because user queues may still access it
*/
unsigned int queue_refcount;
- atomic_t userq_va_mapped;
+ /* Indicates if this buffer is mapped for any user queue. Once set, never reset. */
+ bool userq_va_mapped;
};
struct amdgpu_bo {