Kill automatic charging restart to retain manual control.
authorBalaji Rao <balajirrao@openmoko.org>
Mon, 29 Dec 2008 12:11:35 +0000 (12:11 +0000)
committerAndy Green <agreen@pads.home.warmcat.com>
Mon, 29 Dec 2008 12:11:35 +0000 (12:11 +0000)
Signed-off-by: Balaji Rao <balajirrao@openmoko.org>

drivers/power/pcf50633-charger.c

index b06a2ed..866972b 100644 (file)
@@ -364,6 +364,12 @@ int __init pcf50633_mbc_probe(struct platform_device *pdev)
        if (ret)
                dev_err(pcf->dev, "failed to register ac\n");
 
+       /* Disable automatic charging restart. Manually setting RESUME
+        * won't have effect otherwise
+        */
+       pcf50633_reg_clear_bits(pcf, PCF50633_REG_MBCC1,
+                                       PCF50633_MBCC1_AUTORES);
+
        return sysfs_create_group(&pdev->dev.kobj, &mbc_attr_group);
 }