Commit 9cae262c authored by Slava Monich's avatar Slava Monich

[ril] Retry data call on PDP_FAIL_ERROR_UNSPECIFIED. Fixes JB#35406

According to comment in android's ril.h, if data call setup fails
with status PDP_FAIL_ERROR_UNSPECIFIED, then we need to silently
retry the call.
parent 5e23459b
......@@ -158,6 +158,7 @@ struct ril_data_request_setup {
char *password;
enum ofono_gprs_proto proto;
enum ofono_gprs_auth_method auth_method;
int retry_count;
};
struct ril_data_request_deact {
......@@ -686,8 +687,6 @@ static void ril_data_call_setup_cb(GRilIoChannel *io, int ril_status,
struct ril_data_call_list *list = NULL;
struct ril_data_call *call = NULL;
ril_data_request_completed(req);
if (ril_status == RIL_E_SUCCESS) {
list = ril_data_call_list_parse(data, len);
}
......@@ -701,6 +700,22 @@ static void ril_data_call_setup_cb(GRilIoChannel *io, int ril_status,
}
}
if (call && call->status == PDP_FAIL_ERROR_UNSPECIFIED &&
!setup->retry_count) {
/*
* Retry silently according to comment in ril.h
* (no more than once though)
*/
DBG("retrying silently");
setup->retry_count++;
req->pending_id = 0;
req->submit(req);
ril_data_call_list_free(list);
return;
}
ril_data_request_completed(req);
if (call && call->status == PDP_FAIL_NONE) {
if (ril_data_call_list_move_calls(self->data_calls, list) > 0) {
DBG("data call(s) added");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment