diff options
author | Ashok Vuyyuru <avuyyuru@codeaurora.org> | 2018-11-13 01:33:58 -0800 |
---|---|---|
committer | Ashok Vuyyuru <avuyyuru@codeaurora.org> | 2019-07-18 12:26:19 +0530 |
commit | 11f32918f835c65b4b084a161a5e1e65abca201c (patch) | |
tree | 08b6507db32f1f6c79b0ba9736801c6279e41720 /ipacm/src/IPACM_Main.cpp | |
parent | f71934d3123837969e04fa199c6b089be67f4496 (diff) | |
download | android_vendor_qcom_opensource_data-ipa-cfg-mgr-11f32918f835c65b4b084a161a5e1e65abca201c.tar.gz android_vendor_qcom_opensource_data-ipa-cfg-mgr-11f32918f835c65b4b084a161a5e1e65abca201c.tar.bz2 android_vendor_qcom_opensource_data-ipa-cfg-mgr-11f32918f835c65b4b084a161a5e1e65abca201c.zip |
ipacm: add dynamic support for ipa coalesce
For each modem PDN, add dynamic IPA coalesce
enable/disable support on TCP/UDP connections.
Change-Id: Icb75be29e250468ded7a8b36170f4732206e8d85
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(); |