Ticket #4401 (closed defect: fixed)

Opened 7 years ago

Last modified 7 years ago

Sugar battery capacity does not update

Reported by: rsmith Owned by: kimquirk
Priority: blocker Milestone: 8.2.0 (was Update.2)
Component: power manager (OHM) Version:
Keywords: Cc: marco, cjb, hughsient, dilinger, rafael
Action Needed: Verified: no
Deployments affected: Blocked By:
Blocking:

Description

The capacity indicator in sugar does not update as the capacity of the battery changes. I think the reason for this is because the 1% SCI events are masked to prevent being woken up from sleep.

The eventual solution to this is to mask the SCI events when we go to sleep and then to unmask them during normal operation. OHM also needs to start deciding when the system is idle and put the system to sleep.

Until these things are in place sugar will have to poll for battery capacity changes. I think that every 3 to 5 minutes should be enough. 1% capacity changes happen about every 100 seconds.

Change History

  Changed 7 years ago by marco

  • owner changed from marco to hughsient@…
  • component changed from sugar to power manager (OHM)

Sugar is not involved at all here, it just listen on HAL property changes. I'm assigning to power-manager which, even if not completely correct, seem a better component for this. Jim, if you actually want me to look into this problem at the HAL level please reassign to me.

  Changed 7 years ago by kimquirk

  • cc rsmith added
  • priority changed from normal to blocker
  • milestone changed from Never Assigned to First Deployment, V1.0

follow-up: ↓ 4   Changed 7 years ago by kimquirk

  • cc cjb added
  • owner changed from hughsient@… to rsmith

in reply to: ↑ 3   Changed 7 years ago by rsmith

  • cc hughsient added
  • owner changed from rsmith to marco

Replying to kimquirk:

Yes. Marco please look into this. We just need _some_ sort of workaround. So it does not matter if its in Sugar or HAL. Wherever its easiest to apply and then un-apply once proper idle detection works and the battery capacity SCI's are unmasked. I would just fix it myself but my initial poking around didn't go anywhere. I'll be happy to come up with some sort of fix if you can get me in the general vicinity of the code that is responsible for this.

  Changed 7 years ago by marco

  • cc marco added; rsmith removed
  • owner changed from marco to rsmith

I think rsmith is trying to solve this for real at ohm/kernel level.

  Changed 7 years ago by dilinger

Longer term, we need to fix OHM or sugar. In the short term, we'll work around it in the kernel by enabling SoC SCI events during normal operation, but shut them prior to suspend.

Patch applied to stable: http://dev.laptop.org/git?p=olpc-2.6;a=commitdiff;h=ca9cca5c8f9a66a350d13c159b8fd1279406dbd6

  Changed 7 years ago by dilinger

(should probably be downgraded in priority?)

  Changed 7 years ago by dilinger

  • cc dilinger added

  Changed 7 years ago by RafaelOrtiz

  • cc rafael added

  Changed 7 years ago by wmb@…

  • owner changed from rsmith to kimquirk

Need someone to test this, cjb can give recipe.

  Changed 7 years ago by jg

  • status changed from new to closed
  • resolution set to fixed
Note: See TracTickets for help on using tickets.