Warning: Can't synchronize with repository "(default)" (No changeset 96d22ec3fa3ef6de3ea8dc0d7d398adc9aa071cf in the repository). Look in the Trac log for more information.

Ticket #404 (closed defect: fixed)

Opened 4 years ago

Last modified 4 years ago

CPU resource stays requested in some situations

Reported by: ainulindale Owned by: mickey
Priority: blocker Milestone: milestone5.5
Component: framework/oeventsd Version:
Keywords: Cc: seba.dos1@…, tommy.b@…

Description

Use case :

Make a call with no carrier Call is outgoing and immediately released Meanwhile oeventsd picks up the outgoing signal, and requests the CPU resource. This resource will stay requested as long as it won't be explicitely not requested.

Logs follow. Please check line 420. ophonekitd.log is given as a proof that it won't receive idle status suspend.

Attachments

frameworkd.log (119.4 KB) - added by ainulindale 4 years ago.
Frameworkd log
ophonekitd.log (16.1 KB) - added by ainulindale 4 years ago.
Ophonekitd log
display-resource-never-released.log (40.1 KB) - added by tommyb 4 years ago.
Part of frameworkd.log where Display resource doesn't get released after missed call
call_updatepending_when_untriggering_occupyresource.patch (937 bytes) - added by tommyb 4 years ago.
Patch that tries to make sure that ReleaseResource? is correctly called

Change History

Changed 4 years ago by ainulindale

Frameworkd log

Changed 4 years ago by ainulindale

Ophonekitd log

comment:1 Changed 4 years ago by jluebbe

Could you post your rules.yaml? If it is the same as the default, it think it is a problem in oeventsd, there are race conditions in the CallStatus? handling. The problems with it's design are really showing up now... :/

comment:2 Changed 4 years ago by ainulindale

It's the same as default, and the log shows clearly there is a race (line 420)

comment:3 Changed 4 years ago by mickey

  • Status changed from new to assigned
  • Owner changed from jluebbe to mickey

comment:4 Changed 4 years ago by mickey

  • Status changed from assigned to in_testing

The new queued resource handling should have fixed this bug. => testing.

comment:5 Changed 4 years ago by dos

  • Cc seba.dos1@… added

comment:6 Changed 4 years ago by tommyb

  • Cc tommy.b@… added

I'm still seeing problems like this with SHR-unstable 20090703 with current frameworkd and fsousaged. I can reliably reproduce it by letting my Freerunner suspend, calling it from my landline and immediately hanging up when the Freerunner has woken up and the call is displayed. After that, the Display resource doesn't get released (see the attached part of frameworkd.log), the display stays on and auto-suspend doesn't work anymore.

After some investigation, I think I've found a bug in oeventsd's fso_actions.py: If OccupyResource? is untriggered before the trigger has been completed (i.e. before onResourceRequestReply has been executed), then ReleaseResource? doesn't get called. The attached patch seems to fix this.

Changed 4 years ago by tommyb

Part of frameworkd.log where Display resource doesn't get released after missed call

Changed 4 years ago by tommyb

Patch that tries to make sure that ReleaseResource? is correctly called

comment:7 Changed 4 years ago by mickey

Applied, thanks a lot!

comment:8 Changed 4 years ago by stefan

  • Status changed from in_testing to closed
  • Resolution set to fixed

With the patch applied it should work. If not please reopen.

Note: See TracTickets for help on using tickets.