Code review comment for lp:~kdub/powerd/fix-1258655

Revision history for this message
Kevin DuBois (kdub) wrote :

unity-mir gets two on's from one button press, one from http://bazaar.launchpad.net/~phablet-team/powerd/trunk/view/head:/src/display.c#L415 and one from http://bazaar.launchpad.net/~phablet-team/powerd/trunk/view/head:/src/display.c#L263. The two on's don't happen everytime, they happen like races.

This isn't a dbus race, that code all checked out (best I can tell). Its that two requests are actually sent out in response to a button press. Sometimes the FB is not ready when one of these 'on' requests happens.

From mir's perspective, all the errors emanate from the FB device not being able to post/blank/etc. Best I can tell, the FB is sometimes not available from a power perspective when one of the on calls comes.

my theory about this problem goes something like this:

power button press
update_display_state()
request_sys_state_internal()
   (request to come out of suspend)
display_set_power_mode()
                                   fb comes out of suspend
                                   fb monitor thread calls update_display_state()

I can check the other devices

« Back to merge proposal