Merge lp://qastaging/~awe/phablet-extras/ofono-socket-exit into lp://qastaging/phablet-extras/ofono

Proposed by Tony Espy
Status: Merged
Approved by: Ricardo Salveti
Approved revision: 45
Merged at revision: 44
Proposed branch: lp://qastaging/~awe/phablet-extras/ofono-socket-exit
Merge into: lp://qastaging/phablet-extras/ofono
Diff against target: 55 lines (+10/-13)
2 files modified
debian/changelog (+6/-0)
gril/gril.c (+4/-13)
To merge this branch: bzr merge lp://qastaging/~awe/phablet-extras/ofono-socket-exit
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Approve
Ricardo Salveti (community) Approve
Review via email: mp+171355@code.qastaging.launchpad.net

Commit message

[gril] Exit if errors occur during RILD socket intialization.

Description of the change

This changes causes ofono to exit if errors are encountered trying to connect to the RILD socket. This should allow upstart to restart ofono, and if too many errors occur in too short a time period, upstart will mark ofono as failed and give up. This is a better approach than the current code which just ends-up in an un-usable state.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Continuous integration, rev:42
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https://code.launchpad.net/~awe/phablet-extras/ofono-socket-exit/+merge/171355/+edit-commit-message

http://jenkins.qa.ubuntu.com/job/phablet-extras-ofono-ci/41/
Executed test runs:
    SUCCESS: http://jenkins.qa.ubuntu.com/job/phablet-extras-ofono-saucy-armhf-ci/16
        deb: http://jenkins.qa.ubuntu.com/job/phablet-extras-ofono-saucy-armhf-ci/16/artifact/work/output/*zip*/output.zip

Click here to trigger a rebuild:
http://s-jenkins:8080/job/phablet-extras-ofono-ci/41/rebuild

review: Needs Fixing (continuous-integration)
43. By Tony Espy

Re-merge from trunk.

44. By Tony Espy

Fixed changelog merge error.

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Ricardo Salveti (rsalveti) wrote :

32 - /* TODO: this should have retry logic... */
33 + ril->connected = FALSE;

Please let the todo as this is not yet the final solution. This code would break the logic in case ofono is loaded but it's expected that rild is not available.

I do believe we should improve the code to give make it try to load the modem for a few times, and then just return load error instead.

review: Needs Fixing
Revision history for this message
Tony Espy (awe) wrote :

We've discussed this approach for over a week, and this is the first time I've heard your opposition to this approach.

With regards to the case where ofono is started, but it's expected that rild isn't available, I've stated in the past that the best approach to solving this is to not enable the device plugin ( plugins/ril ) in the first place. The standard technique that ofono uses is a udevng plugin, which wasn't used originally as we didn't run udev in our Ubuntyu container. The udev approach also isn't really the best approach to determining that a device runs rild.

So another approach would be to write a new plugin which understands how to query the Android properties and only enable the ril plugin based upon the values of one or more ril-specific properties.

I really would prefer not to put hard retry limits on the RILD socket in the code. Upstart has the ability to cap restarts over a given time period, which couldn't be leveraged if the retries are in the /gril layer.

45. By Tony Espy

Update debian/changelog to UNRELEASED.

Revision history for this message
Ricardo Salveti (rsalveti) wrote :

We discussed over mumble, and we decided to move forward with this change and later improve the modem detection part to only enable ril in case it's available in the system (probably via properties).

review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches