twl4030_charger: reduce default charge_current for usb
authorGrazvydas Ignotas <notasas@gmail.com>
Thu, 4 Jul 2013 22:41:15 +0000 (01:41 +0300)
committerGrazvydas Ignotas <notasas@gmail.com>
Thu, 4 Jul 2013 22:54:18 +0000 (01:54 +0300)
I've recently encountered a PC that has USB ports that limit current
draw to ~600mA - if more is drawn it cuts VBUS out. Incidentally pandora
has charge_current set to ~600mA, so on that PC charging only lasted for
a few secs and went out. Reducing the current to way below 600mA makes
charging reliable from that PC USB ports, and ~7% slower charging should
not make that much difference.

drivers/power/twl4030_charger.c

index 417934b..9488b37 100644 (file)
@@ -775,7 +775,7 @@ static int __init twl4030_bci_probe(struct platform_device *pdev)
        bci->irq_chg = platform_get_irq(pdev, 0);
        bci->irq_bci = platform_get_irq(pdev, 1);
        bci->ac_current = 860; /* ~1.2A */
-       bci->usb_current = 360; /* ~600mA */
+       bci->usb_current = 330; /* ~560mA */
        bci->irq_had_charger = -1;
        bci->irq_check_count_time = jiffies;