Messages in this thread | | | From | <> | Subject | RE: [PATCH 1/1] power_supply: wilco_ec: Add permanent long life charging mode | Date | Wed, 24 Jun 2020 03:51:38 +0000 |
| |
> > > Since this is normally only done in the factory context, can you > > > please confirm does something need to be artificially done to block > > > userland from trying to set the battery charging to this mode? Or > > > will the EC already > > handle > > > blocking it directly? > > > > This is a feature of the battery, when the EC receives this setting it > > will be sent to the battery and stored there. Afterwards any attempt > > to change this mode will return a failure. > > Sorry this still isn't clear to me. You're saying that if EC receives longlife > setting it will be able to do this in the field? If so, then I think this patch will > need to block that setting to not allow field conversions into longlife mode. > EC does handle blocking the attempts from changing the mode.
EC reads current mode ahead of a new setting. If it sees permanent long life already in use then any attempt to put the battery charging in a different mode will get failure 0x01 from EC.
> > > > It's even better to block mode selection in the userland if long life > > mode already in use. > > Yes, I agree. This sounds like a good follow up to me too.
| |