Skip to content
Commit bea10413 authored by Mario Kleiner's avatar Mario Kleiner Committed by Alex Deucher
Browse files

drm/amdgpu: Fix overflow of watermark calcs at > 4k resolutions.



Commit d63c277d
("drm/amdgpu: Make display watermark calculations more accurate")
made watermark calculations more accurate, but not for > 4k
resolutions on 32-Bit architectures, as it introduced an integer
overflow for those setups and resolutions.

Fix this by proper u64 casting and division.

Signed-off-by: default avatarMario Kleiner <mario.kleiner.de@gmail.com>
Reported-by: default avatarBen Hutchings <ben.hutchings@codethink.co.uk>
Fixes: d63c277d ("drm/amdgpu: Make display watermark calculations more accurate")
Cc: Ben Hutchings <ben.hutchings@codethink.co.uk>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent c0f83da9
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment