drm/amdgpu: Make display watermark calculations more accurate
authorMario Kleiner <mario.kleiner.de@gmail.com>
Wed, 29 Mar 2017 20:09:11 +0000 (22:09 +0200)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 7 Apr 2017 16:20:42 +0000 (12:20 -0400)
commitd63c277dc672e0c568481af043359420fa9d4736
tree5f53fc911a8a970413c815af7caf2304269d53db
parent211eed656b0ec13240aaaa42bd6541f1fcb61007
drm/amdgpu: Make display watermark calculations more accurate

Avoid big roundoff errors in scanline/hactive durations for
high pixel clocks, especially for >= 500 Mhz, and thereby
program more accurate display fifo watermarks.

Implemented here for DCE 6,8,10,11.
Successfully tested on DCE 10 with AMD R9 380 Tonga.

Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
drivers/gpu/drm/amd/amdgpu/dce_v6_0.c
drivers/gpu/drm/amd/amdgpu/dce_v8_0.c