diff options
author | Samuel Pitoiset <samuel.pitoiset@gmail.com> | 2017-02-09 11:33:37 +0100 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2017-02-09 11:29:44 -0500 |
commit | fad061270ac43ff9eed315f0eae7c40b694592de (patch) | |
tree | 8d3b407141622c4addc4898b9b9c4192d332c30e /drivers/gpu/drm/amd/amdgpu/amdgpu.h | |
parent | 38fc4856ad98f230bc91da0421dec69e4aee40f8 (diff) | |
download | lwn-fad061270ac43ff9eed315f0eae7c40b694592de.tar.gz lwn-fad061270ac43ff9eed315f0eae7c40b694592de.zip |
drm/amdgpu: report the number of bytes moved at buffer creation
Like ttm_bo_validate(), ttm_bo_init() might need to move BO and
the number of bytes moved by TTM should be reported. This can help
the throttle buffer migration mechanism to make a better decision.
v2: fix computation
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu.h')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gpu/drm/amd/amdgpu/amdgpu.h index 94a64e3bc682..96ad79627dbb 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu.h +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu.h @@ -1709,6 +1709,7 @@ int amdgpu_cs_parser_init(struct amdgpu_cs_parser *p, void *data); int amdgpu_cs_get_ring(struct amdgpu_device *adev, u32 ip_type, u32 ip_instance, u32 ring, struct amdgpu_ring **out_ring); +void amdgpu_cs_report_moved_bytes(struct amdgpu_device *adev, u64 num_bytes); void amdgpu_ttm_placement_from_domain(struct amdgpu_bo *abo, u32 domain); bool amdgpu_ttm_bo_is_amdgpu_bo(struct ttm_buffer_object *bo); int amdgpu_ttm_tt_get_user_pages(struct ttm_tt *ttm, struct page **pages); |