diff options
author | Alex Xie <AlexBin.Xie@amd.com> | 2017-01-28 21:50:44 +0200 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2017-02-02 15:22:53 -0500 |
commit | fe7cb34eda1855ac9770bc9f3e582897000e41b0 (patch) | |
tree | 1f9b794b15dc3a73ad9e1092ed1c4992ea8572cd /amdgpu/amdgpu_internal.h | |
parent | 067e9a1d47a8373b3145481a70fec84ce8e76441 (diff) | |
download | libdrm-fe7cb34eda1855ac9770bc9f3e582897000e41b0.tar.gz libdrm-fe7cb34eda1855ac9770bc9f3e582897000e41b0.tar.bz2 libdrm-fe7cb34eda1855ac9770bc9f3e582897000e41b0.zip |
amdgpu: vamgr can be a struct instead of a pointer
vamgr is an integral part of amdgpu_device. We don't need to calloc and free it.
This can save CPU time, reduce heap fragmentation.
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Signed-off-by: Alex Xie <AlexBin.Xie@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
[Grazvydas Ignotas: rebase, correct a typo in commit message]
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'amdgpu/amdgpu_internal.h')
-rw-r--r-- | amdgpu/amdgpu_internal.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/amdgpu/amdgpu_internal.h b/amdgpu/amdgpu_internal.h index 7e237ac1..cf119a53 100644 --- a/amdgpu/amdgpu_internal.h +++ b/amdgpu/amdgpu_internal.h @@ -85,7 +85,7 @@ struct amdgpu_device { struct drm_amdgpu_info_device dev_info; struct amdgpu_gpu_info info; /** The global VA manager for the whole virtual address space */ - struct amdgpu_bo_va_mgr *vamgr; + struct amdgpu_bo_va_mgr vamgr; /** The VA manager for the 32bit address space */ struct amdgpu_bo_va_mgr vamgr_32; }; |