Re: [PATCH v2] backlight: pwm_bl: Fix brightness levels for non-DT case.
From: Uwe Kleine-König <hidden>
Date: 2018-11-06 20:53:18
Also in:
dri-devel, linux-pwm, lkml, stable
From: Uwe Kleine-König <hidden>
Date: 2018-11-06 20:53:18
Also in:
dri-devel, linux-pwm, lkml, stable
On Tue, Oct 30, 2018 at 11:34:41AM +0100, Enric Balletbo i Serra wrote:
Commit '88ba95bedb79 ("backlight: pwm_bl: Compute brightness of LED
linearly to human eye")' allows the possibility to compute a default
brightness table when there isn't the brightness-levels property in the
DT. Unfortunately the changes made broke the pwm backlight for the
non-DT boards.
Usually, the non-DT boards don't pass the brightness levels via platform
data, instead, it sets the max_brightness in their platform data and the
driver calculates the level without a table. The ofending patch assumeds/ofending/offending/
hat when there is no brightness levels table we should create one, but this
s/hat/that/
is clearly wrong for the non-DT case.
After this patch the code handles the DT and the non-DT case taking in
consideration also if max_brightness is set or not.
Fixes: '88ba95bedb79 ("backlight: pwm_bl: Compute brightness of LED linearly to human eye")'These ' are unusual. Best regards Uwe -- Pengutronix e.K. | Uwe Kleine-König | Industrial Linux Solutions | http://www.pengutronix.de/ |