forked from Minki/linux
pwm: pca9685: Reset OFF/ON registers to POR value
During the driver probe, registers are not set to their POR value. Signed-off-by: Lionel Vitte <lionel.vitte@free.fr> Acked-by: Clemens Gruber <clemens.gruber@pqgruber.com> Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
This commit is contained in:
parent
dc1adb3ce4
commit
2e0e12967e
@ -560,10 +560,10 @@ static int pca9685_pwm_probe(struct i2c_client *client,
|
||||
pca9685_write_reg(pca, PCA9685_MODE1, reg);
|
||||
|
||||
/* Reset OFF/ON registers to POR default */
|
||||
pca9685_write_reg(pca, PCA9685_ALL_LED_OFF_L, LED_FULL);
|
||||
pca9685_write_reg(pca, PCA9685_ALL_LED_OFF_L, 0);
|
||||
pca9685_write_reg(pca, PCA9685_ALL_LED_OFF_H, LED_FULL);
|
||||
pca9685_write_reg(pca, PCA9685_ALL_LED_ON_L, 0);
|
||||
pca9685_write_reg(pca, PCA9685_ALL_LED_ON_H, 0);
|
||||
pca9685_write_reg(pca, PCA9685_ALL_LED_ON_H, LED_FULL);
|
||||
|
||||
pca->chip.ops = &pca9685_pwm_ops;
|
||||
/* Add an extra channel for ALL_LED */
|
||||
|
Loading…
Reference in New Issue
Block a user