diff options
| author | Chunming Zhou <[email protected]> | 2017-04-13 08:16:51 +0000 |
|---|---|---|
| committer | Alex Deucher <[email protected]> | 2017-04-28 21:32:53 +0000 |
| commit | 05a72a2864c2b27471e9f5365448563c78f9b114 (patch) | |
| tree | 9671643ec131395d27c2e431555bddc7a86eabdf /drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c | |
| parent | drm/amdgpu: fix amdgpu_ttm_bo_eviction_valuable (diff) | |
| download | kernel-05a72a2864c2b27471e9f5365448563c78f9b114.tar.gz kernel-05a72a2864c2b27471e9f5365448563c78f9b114.zip | |
drm/amdgpu: add gtt print like vram when dump mm table V2
Signed-off-by: Chunming Zhou <[email protected]>
Reviewed-by: Christian König <[email protected]>
Reviewed-by: Alex Deucher <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c')
| -rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c index 0335c2f331e9..f7d22c44034d 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c @@ -134,6 +134,15 @@ int amdgpu_gtt_mgr_alloc(struct ttm_mem_type_manager *man, return r; } +void amdgpu_gtt_mgr_print(struct seq_file *m, struct ttm_mem_type_manager *man) +{ + struct amdgpu_device *adev = amdgpu_ttm_adev(man->bdev); + struct amdgpu_gtt_mgr *mgr = man->priv; + + seq_printf(m, "man size:%llu pages, gtt available:%llu pages, usage:%lluMB\n", + man->size, mgr->available, (u64)atomic64_read(&adev->gtt_usage) >> 20); + +} /** * amdgpu_gtt_mgr_new - allocate a new node * |
