power: axp818: Fix typo in axp_set_dldo
authorOndrej Jirman <megous@megous.com>
Wed, 13 Feb 2019 17:51:05 +0000 (18:51 +0100)
committerJagan Teki <jagan@amarulasolutions.com>
Fri, 8 Mar 2019 06:06:59 +0000 (11:36 +0530)
Fix typo in axp_set_dldo() so that it correctly uses AXP818_DLDO1_CTRL
register to configure the voltage instead of setting AXP818_ELDO1_CTRL
register which is obviously incorrect.

Signed-off-by: Ondřej Jirman <megous@megous.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>
drivers/power/axp818.c

index c737da1180fb53c0348a101114a26ffbb9dd9836..834919ddd4c189af7d16d5e956eb1903315153d4 100644 (file)
@@ -161,7 +161,7 @@ int axp_set_dldo(int dldo_num, unsigned int mvolt)
        cfg = axp818_mvolt_to_cfg(mvolt, 700, 3300, 100);
        if (dldo_num == 2 && mvolt > 3300)
                cfg += 1 + axp818_mvolt_to_cfg(mvolt, 3400, 4200, 200);
-       ret = pmic_bus_write(AXP818_ELDO1_CTRL + (dldo_num - 1), cfg);
+       ret = pmic_bus_write(AXP818_DLDO1_CTRL + (dldo_num - 1), cfg);
        if (ret)
                return ret;