aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c
diff options
context:
space:
mode:
authorChristian König <christian.koenig@amd.com>2018-01-09 13:32:58 -0500
committerAlex Deucher <alexander.deucher@amd.com>2018-02-19 14:17:46 -0500
commitc35ff18823f877459b2b4ace61fb08a9b56106f9 (patch)
treeb50c86bb2bd8e2b8d6ddf6d846c37fe405c3fafc /drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c
parent5c2ff9a60d2123df1e4ccee363541dd17916ddea (diff)
drm/amdgpu: trace allocated PASIDs
Trace all allocated PASIDs. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Chunming Zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c
index 842caa5ed73b..3b9d318cf166 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c
@@ -69,6 +69,9 @@ int amdgpu_pasid_alloc(unsigned int bits)
69 break; 69 break;
70 } 70 }
71 71
72 if (pasid >= 0)
73 trace_amdgpu_pasid_allocated(pasid);
74
72 return pasid; 75 return pasid;
73} 76}
74 77
@@ -78,6 +81,7 @@ int amdgpu_pasid_alloc(unsigned int bits)
78 */ 81 */
79void amdgpu_pasid_free(unsigned int pasid) 82void amdgpu_pasid_free(unsigned int pasid)
80{ 83{
84 trace_amdgpu_pasid_freed(pasid);
81 ida_simple_remove(&amdgpu_pasid_ida, pasid); 85 ida_simple_remove(&amdgpu_pasid_ida, pasid);
82} 86}
83 87