diff options
Diffstat (limited to 'ipacm/src/IPACM_Main.cpp')
-rw-r--r-- | ipacm/src/IPACM_Main.cpp | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/ipacm/src/IPACM_Main.cpp b/ipacm/src/IPACM_Main.cpp index 04f8a89..eef15d9 100644 --- a/ipacm/src/IPACM_Main.cpp +++ b/ipacm/src/IPACM_Main.cpp @@ -240,6 +240,10 @@ void* ipa_driver_msg_notifier(void *param) #endif struct ipa_get_data_stats_resp_msg_v01 event_data_stats; struct ipa_get_apn_data_stats_resp_msg_v01 event_network_stats; +#ifdef IPA_RT_SUPPORT_COAL + struct ipa_coalesce_info coalesce_info; +#endif + #ifdef FEATURE_IPACM_HAL IPACM_OffloadManager* OffloadMng; #endif @@ -821,6 +825,40 @@ void* ipa_driver_msg_notifier(void *param) evt_data.evt_data = mapping; break; #endif +#ifdef IPA_RT_SUPPORT_COAL + case IPA_COALESCE_ENABLE: + memcpy(&coalesce_info, buffer + sizeof(struct ipa_msg_meta), sizeof(struct ipa_coalesce_info)); + IPACMDBG_H("Received IPA_COALESCE_ENABLE qmap-id:%d tcp:%d, udp%d\n", + coalesce_info.qmap_id, coalesce_info.tcp_enable, coalesce_info.udp_enable); + if (coalesce_info.qmap_id >=IPA_MAX_NUM_SW_PDNS) + { + IPACMERR("qmap_id (%d) beyond the Max range (%d), abort\n", + coalesce_info.qmap_id, IPA_MAX_NUM_SW_PDNS); + return NULL; + } + IPACM_Wan::coalesce_config(coalesce_info.qmap_id, coalesce_info.tcp_enable, coalesce_info.udp_enable); + /* Notify all LTE instance to do RSC configuration */ + evt_data.event = IPA_COALESCE_NOTICE; + evt_data.evt_data = NULL; + break; + + case IPA_COALESCE_DISABLE: + memcpy(&coalesce_info, buffer + sizeof(struct ipa_msg_meta), sizeof(struct ipa_coalesce_info)); + IPACMDBG_H("Received IPA_COALESCE_DISABLE qmap-id:%d tcp:%d, udp%d\n", + coalesce_info.qmap_id, coalesce_info.tcp_enable, coalesce_info.udp_enable); + if (coalesce_info.qmap_id >=IPA_MAX_NUM_SW_PDNS) + { + IPACMERR("qmap_id (%d) beyond the Max range (%d), abort\n", + coalesce_info.qmap_id, IPA_MAX_NUM_SW_PDNS); + return NULL; + } + IPACM_Wan::coalesce_config(coalesce_info.qmap_id, false, false); + /* Notify all LTE instance to do RSC configuration */ + evt_data.event = IPA_COALESCE_NOTICE; + evt_data.evt_data = NULL; + break; +#endif + default: IPACMDBG_H("Unhandled message type: %d\n", event_hdr.msg_type); continue; @@ -912,6 +950,8 @@ int main(int argc, char **argv) IPACMDBG_H("Staring IPA main\n"); IPACMDBG_H("ipa_cmdq_successful\n"); + /* reset coalesce settings */ + IPACM_Wan::coalesce_config_reset(); RegisterForSignals(); |