Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

backlight: lm3630a: explicitly apply PWM config extracted from pwm_args

Call pwm_apply_args() just after requesting the PWM device so that the
polarity and period are initialized according to the information
provided in pwm_args.

This is an intermediate state, and pwm_apply_args() should be dropped as
soon as the atomic PWM infrastructure is in place and the driver makes
use of it.

Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>

authored by

Boris Brezillon and committed by
Thierry Reding
7ff666bc 6fbab835

+6
+6
drivers/video/backlight/lm3630a_bl.c
··· 424 424 dev_err(&client->dev, "fail : get pwm device\n"); 425 425 return PTR_ERR(pchip->pwmd); 426 426 } 427 + 428 + /* 429 + * FIXME: pwm_apply_args() should be removed when switching to 430 + * the atomic PWM API. 431 + */ 432 + pwm_apply_args(pchip->pwmd); 427 433 } 428 434 429 435 /* interrupt enable : irq 0 is not allowed */