]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - drivers/regulator/tps65910-regulator.c
regulator: tps65910: fix a missing check of return value
[mirror_ubuntu-bionic-kernel.git] / drivers / regulator / tps65910-regulator.c
index 81672a58fcc234f381a40c3b43eda132a6dd96a5..194fa0cbbc048176bdf0e326269abed2b52043a6 100644 (file)
@@ -1102,8 +1102,10 @@ static int tps65910_probe(struct platform_device *pdev)
        platform_set_drvdata(pdev, pmic);
 
        /* Give control of all register to control port */
-       tps65910_reg_set_bits(pmic->mfd, TPS65910_DEVCTRL,
+       err = tps65910_reg_set_bits(pmic->mfd, TPS65910_DEVCTRL,
                                DEVCTRL_SR_CTL_I2C_SEL_MASK);
+       if (err < 0)
+               return err;
 
        switch (tps65910_chip_id(tps65910)) {
        case TPS65910: