[SHR-Unstable] Forcing fast-charge

Rask Ingemann Lambertsen rask at sygehus.dk
Sun Apr 26 19:14:07 CEST 2009

On Sat, Apr 25, 2009 at 01:16:17PM +0100, Joerg Reisenweber wrote:
> Am Di  21. April 2009 schrieb Paul Fertser:
> > 
> > drivers/power/pcf50633-charger.c:
> > 
> > /*
> > * We limit the charging current to be the USB current limit.
> > * The reason is that on pcf50633, when it enters PMU Standby mode,
> > * which it does when the device goes "off", the USB current limit
> > * reverts to the variant default.  In at least one common case, that
> > * default is 500mA.  By setting the charging current to be the same
> > * as the USB limit we set here before PMU standby, we enforce it only
> > * using the correct amount of current even when the USB current limit
> > * gets reset to the wrong thing
> > */     
> Whoever wrote this amazingly puzzling comment, I think he got something 
> severely wrong with operating principles of PMU PCF50633.
> Datasheet of PMU clearly states there's no situation whatever that could 
> result in batcharge current overloading the USB_CURLIM,

   The comment doesn't claim there is.

> as *allways* there 
> will be priority on serving system by providing up to 100% of usb current to 
> power it.

   Serving the system takes 0 mA in this particular case, because the device
is off.

> Bat charge will get whatever might remain after that, *up_to* the 
> charging limit programmed into PMU.


> As we may charge our battery with 1C (=1200mA) it's perfectly safe to set bat 
> chg curlim to that value, and rely on PMU managing distribution of actual USB 
> supply current to system and charging according to the momentary needs.

   The problem is not that of staying under the 1200 mA permitted for the
battery. The problem is staying under the maximum USB current, which may be
as little as 100 mA.  We just can't do anything about the USB current limit
being reset to 500 mA, but we _can_ keep the charging current limited to 100
mA, which is good enough when the only consumer is the the battery charger.

Rask Ingemann Lambertsen
Danish law requires addresses in e-mail to be logged and stored for a year

More information about the community mailing list