[U-Boot] [PATCH v2] sunxi: display: Use PWM to drive backlight where applicable
Peter Korsgaard
peter at korsgaard.com
Fri Aug 26 16:15:56 CEST 2016
>>>>> "Hans" == Hans de Goede <hdegoede at redhat.com> writes:
> When the backlight's pwm input is connected to a pwm output of the SoC,
> actually use pwm to drive the backlight.
> The mean reason for doing this is to fix the backlight turning off
> for aprox. 1 second while the kernel is booting. This is caused by
> the kernel actually using pwm to drive the backlight, so that it
> can dim the backlight. First the pwm driver loads and switches the
> pinmux for the pin driving the backlight's pwm input to the pwm
> controller. Then about 1s later the actual backlight driver loads
> and tells the pwm driver to actually update the pwm settings, which
> have a power-on-reset value of "off".
> An additional advantage is that this allows us to initatiate the
> backlight at 80%, which is the kernel default, avoiding a brightness
> change while the kernel loads.
> +++ b/drivers/video/sunxi_display.c
> @@ -12,6 +12,7 @@
> #include <asm/arch/clock.h>
> #include <asm/arch/display.h>
> #include <asm/arch/gpio.h>
> +#include <asm/arch/pwm.h>
> #include <asm/global_data.h>
> #include <asm/gpio.h>
> #include <asm/io.h>
> @@ -34,7 +35,6 @@
> #define PWM_ON 1
> #define PWM_OFF 0
> #endif
> -
Unrelated white space change. Other than that:
Reviewed by: Peter Korsgaard <peter at korsgaard.com>
--
Bye, Peter Korsgaard
More information about the U-Boot
mailing list