Commit 9c288305 authored by Lauri Tirkkonen's avatar Lauri Tirkkonen Committed by Alex Deucher
Browse files

drm/amd/display: fix initial backlight brightness calculation



DIV_ROUND_CLOSEST(x, 100) returns either 0 or 1 if 0<x<=100, so the
division needs to be performed after the multiplication and not the
other way around, to properly scale the value.

Fixes: 8b5f3a22 ("drm/amd/display: Fix default DC and AC levels")
Signed-off-by: default avatarLauri Tirkkonen <lauri@hacktheplanet.fi>
Cc: stable@vger.kernel.org
Reviewed-by: default avatarMario Limonciello <mario.limonciello@amd.com>
Link: https://lore.kernel.org/r/aH2Q_HJvxKbW74vU@hacktheplanet.fi


Signed-off-by: default avatarMario Limonciello <mario.limonciello@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 1f02f204
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment