Merge "msm: ipa: enable lan coalescing based on config"
diff --git a/drivers/platform/msm/ipa/ipa_v3/ipa.c b/drivers/platform/msm/ipa/ipa_v3/ipa.c
index a3ae29e..11123d1 100644
--- a/drivers/platform/msm/ipa/ipa_v3/ipa.c
+++ b/drivers/platform/msm/ipa/ipa_v3/ipa.c
@@ -6299,7 +6299,7 @@
ipa3_ctx->clnt_hdl_data_in = 0;
if (ipa3_ctx->ipa_hw_type >= IPA_HW_v5_5 &&
- !ipa3_ctx->ipa_config_is_apq_dma) {
+ ipa3_ctx->lan_coal_enable) {
/*
* LAN_COAL IN (IPA->AP)
*/
@@ -9289,6 +9289,7 @@
ipa3_ctx->tx_poll = resource_p->tx_poll;
ipa3_ctx->ipa_gpi_event_rp_ddr = resource_p->ipa_gpi_event_rp_ddr;
ipa3_ctx->rmnet_ctl_enable = resource_p->rmnet_ctl_enable;
+ ipa3_ctx->lan_coal_enable = resource_p->lan_coal_enable;
ipa3_ctx->rmnet_ll_enable = resource_p->rmnet_ll_enable;
ipa3_ctx->tx_wrapper_cache_max_size = get_tx_wrapper_cache_size(
resource_p->tx_wrapper_cache_max_size);
@@ -10578,6 +10579,14 @@
ipa_drv_res->rmnet_ll_enable
? "True" : "False");
}
+ ipa_drv_res->lan_coal_enable =
+ of_property_read_bool(pdev->dev.of_node,
+ "qcom,lan-coal-enable");
+ IPADBG(": Enable lan coal = %s\n",
+ ipa_drv_res->lan_coal_enable
+ ? "True" : "False");
+
+
result = of_property_read_string(pdev->dev.of_node,
"qcom,use-gsi-ipa-fw", &ipa_drv_res->gsi_fw_file_name);
diff --git a/drivers/platform/msm/ipa/ipa_v3/ipa_i.h b/drivers/platform/msm/ipa/ipa_v3/ipa_i.h
index 5eb8ad3..64ef33f 100644
--- a/drivers/platform/msm/ipa/ipa_v3/ipa_i.h
+++ b/drivers/platform/msm/ipa/ipa_v3/ipa_i.h
@@ -2411,6 +2411,7 @@
bool ipa_wdi2_over_gsi;
bool ipa_wdi3_over_gsi;
bool ipa_endp_delay_wa;
+ bool lan_coal_enable;
bool ipa_fltrt_not_hashable;
bool use_xbl_boot;
bool use_64_bit_dma_mask;
@@ -2661,6 +2662,7 @@
bool ipa_gpi_event_rp_ddr;
bool rmnet_ctl_enable;
bool rmnet_ll_enable;
+ bool lan_coal_enable;
bool ipa_use_uc_holb_monitor;
u32 ipa_holb_monitor_poll_period;
u32 ipa_holb_monitor_max_cnt_wlan;
diff --git a/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c b/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c
index 320b780..504b9af 100644
--- a/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c
+++ b/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c
@@ -6818,7 +6818,7 @@
bool lan_coal_enabled()
{
- if ( ipa3_ctx->ipa_initialization_complete ) {
+ if ( ipa3_ctx->ipa_initialization_complete && ipa3_ctx->lan_coal_enable) {
int ep_idx;
if ( IPA_CLIENT_IS_MAPPED_VALID(IPA_CLIENT_APPS_LAN_COAL_CONS, ep_idx) ) {
return true;