GTP WWAN should work even if MSA/MSB is not enabled
GTP WWAN should work even if MSA/MSB is not enabled in capabilities. Removing wifi_nif we don't need it any more. Change-Id: I6736e5f4320d4c35bc5bbb8272b45e14f66988c3 CRs-Fixed: 1067691
This commit is contained in:
parent
3493ce50e4
commit
0ac11fcd84
2 changed files with 17 additions and 31 deletions
|
@ -1248,16 +1248,7 @@ LocEngReqRelWifi::~LocEngReqRelWifi() {
|
||||||
}
|
}
|
||||||
void LocEngReqRelWifi::proc() const {
|
void LocEngReqRelWifi::proc() const {
|
||||||
loc_eng_data_s_type* locEng = (loc_eng_data_s_type*)mLocEng;
|
loc_eng_data_s_type* locEng = (loc_eng_data_s_type*)mLocEng;
|
||||||
if (locEng->wifi_nif) {
|
locEng->adapter->atlOpenStatus(mSenderId, 0, NULL, -1, mType);
|
||||||
WIFISubscriber s(locEng->wifi_nif, mSSID, mPassword, mSenderId);
|
|
||||||
if (mIsReq) {
|
|
||||||
locEng->wifi_nif->subscribeRsrc((Subscriber*)&s);
|
|
||||||
} else {
|
|
||||||
locEng->wifi_nif->unsubscribeRsrc((Subscriber*)&s);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
locEng->adapter->atlOpenStatus(mSenderId, 0, NULL, -1, mType);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
inline void LocEngReqRelWifi::locallog() const {
|
inline void LocEngReqRelWifi::locallog() const {
|
||||||
LOC_LOGV("%s - senderId: %d, ssid: %s, password: %s",
|
LOC_LOGV("%s - senderId: %d, ssid: %s, password: %s",
|
||||||
|
@ -2345,12 +2336,10 @@ void loc_eng_agps_init(loc_eng_data_s_type &loc_eng_data, AGpsExtCallbacks* call
|
||||||
EXIT_LOG(%s, VOID_RET);
|
EXIT_LOG(%s, VOID_RET);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
bool agpsCapable = ((gps_conf.CAPABILITIES & GPS_CAPABILITY_MSA) ||
|
|
||||||
(gps_conf.CAPABILITIES & GPS_CAPABILITY_MSB));
|
|
||||||
LocEngAdapter* adapter = loc_eng_data.adapter;
|
LocEngAdapter* adapter = loc_eng_data.adapter;
|
||||||
loc_eng_data.agps_status_cb = callbacks->status_cb;
|
loc_eng_data.agps_status_cb = callbacks->status_cb;
|
||||||
|
|
||||||
if (agpsCapable && NULL != adapter) {
|
if (NULL != adapter) {
|
||||||
if (adapter->mSupportsAgpsRequests) {
|
if (adapter->mSupportsAgpsRequests) {
|
||||||
adapter->sendMsg(new LocEngAgnssNifInit(&loc_eng_data));
|
adapter->sendMsg(new LocEngAgnssNifInit(&loc_eng_data));
|
||||||
}
|
}
|
||||||
|
@ -2373,25 +2362,27 @@ static void createAgnssNifs(loc_eng_data_s_type& locEng) {
|
||||||
bool agpsCapable = ((gps_conf.CAPABILITIES & GPS_CAPABILITY_MSA) ||
|
bool agpsCapable = ((gps_conf.CAPABILITIES & GPS_CAPABILITY_MSA) ||
|
||||||
(gps_conf.CAPABILITIES & GPS_CAPABILITY_MSB));
|
(gps_conf.CAPABILITIES & GPS_CAPABILITY_MSB));
|
||||||
LocEngAdapter* adapter = locEng.adapter;
|
LocEngAdapter* adapter = locEng.adapter;
|
||||||
if (agpsCapable && NULL != adapter && adapter->mSupportsAgpsRequests) {
|
if (NULL != adapter && adapter->mSupportsAgpsRequests) {
|
||||||
if (NULL == locEng.internet_nif) {
|
if (NULL == locEng.internet_nif) {
|
||||||
locEng.internet_nif= new AgpsStateMachine(servicerTypeAgps,
|
locEng.internet_nif= new AgpsStateMachine(servicerTypeAgps,
|
||||||
(void *)locEng.agps_status_cb,
|
(void *)locEng.agps_status_cb,
|
||||||
AGPS_TYPE_WWAN_ANY,
|
AGPS_TYPE_WWAN_ANY,
|
||||||
false);
|
false);
|
||||||
}
|
}
|
||||||
if (NULL == locEng.agnss_nif) {
|
if (agpsCapable) {
|
||||||
locEng.agnss_nif = new AgpsStateMachine(servicerTypeAgps,
|
if (NULL == locEng.agnss_nif) {
|
||||||
(void *)locEng.agps_status_cb,
|
locEng.agnss_nif = new AgpsStateMachine(servicerTypeAgps,
|
||||||
AGPS_TYPE_SUPL,
|
(void *)locEng.agps_status_cb,
|
||||||
false);
|
AGPS_TYPE_SUPL,
|
||||||
}
|
false);
|
||||||
if (NULL == locEng.ds_nif &&
|
}
|
||||||
gps_conf.USE_EMERGENCY_PDN_FOR_EMERGENCY_SUPL &&
|
if (NULL == locEng.ds_nif &&
|
||||||
0 == adapter->initDataServiceClient()) {
|
gps_conf.USE_EMERGENCY_PDN_FOR_EMERGENCY_SUPL &&
|
||||||
locEng.ds_nif = new DSStateMachine(servicerTypeExt,
|
0 == adapter->initDataServiceClient()) {
|
||||||
(void *)dataCallCb,
|
locEng.ds_nif = new DSStateMachine(servicerTypeExt,
|
||||||
locEng.adapter);
|
(void *)dataCallCb,
|
||||||
|
locEng.adapter);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2401,10 +2392,6 @@ static AgpsStateMachine*
|
||||||
getAgpsStateMachine(loc_eng_data_s_type &locEng, AGpsExtType agpsType) {
|
getAgpsStateMachine(loc_eng_data_s_type &locEng, AGpsExtType agpsType) {
|
||||||
AgpsStateMachine* stateMachine;
|
AgpsStateMachine* stateMachine;
|
||||||
switch (agpsType) {
|
switch (agpsType) {
|
||||||
case AGPS_TYPE_WIFI: {
|
|
||||||
stateMachine = locEng.wifi_nif;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case AGPS_TYPE_INVALID:
|
case AGPS_TYPE_INVALID:
|
||||||
case AGPS_TYPE_SUPL: {
|
case AGPS_TYPE_SUPL: {
|
||||||
stateMachine = locEng.agnss_nif;
|
stateMachine = locEng.agnss_nif;
|
||||||
|
|
|
@ -105,7 +105,6 @@ typedef struct loc_eng_data_s
|
||||||
// AGPS state machines
|
// AGPS state machines
|
||||||
AgpsStateMachine* agnss_nif;
|
AgpsStateMachine* agnss_nif;
|
||||||
AgpsStateMachine* internet_nif;
|
AgpsStateMachine* internet_nif;
|
||||||
AgpsStateMachine* wifi_nif;
|
|
||||||
//State machine for Data Services
|
//State machine for Data Services
|
||||||
AgpsStateMachine* ds_nif;
|
AgpsStateMachine* ds_nif;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue