mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-24 21:54:34 -04:00
qcacmn: Disable LRO capability during concurrency
LRO rx jumbo packets cannot be forwarded to other vdev and kernel drops them with warning message: "skbuff: wlan0: received packets cannot be forwarded while LRO is enabled" So disable LRO capability during concurrency. Change-Id: Ib35e1ee5f9c18a846e21ce1eb293e12e17761fa8 CRs-Fixed: 1092193
This commit is contained in:
parent
a07e4b97d4
commit
fb82833f38
4 changed files with 65 additions and 0 deletions
|
|
@ -812,6 +812,15 @@ struct policy_mgr_cdp_cbacks {
|
|||
uint8_t vdev_id, uint8_t mac_id);
|
||||
};
|
||||
|
||||
/**
|
||||
* struct policy_mgr_dp_cbacks - CDP Callbacks to be invoked
|
||||
* from policy manager
|
||||
* @hdd_disable_lro_in_concurrency: Callback to disable LRO
|
||||
*/
|
||||
struct policy_mgr_dp_cbacks {
|
||||
void (*hdd_disable_lro_in_concurrency)(bool);
|
||||
};
|
||||
|
||||
/**
|
||||
* struct policy_mgr_wma_cbacks - WMA Callbacks to be invoked
|
||||
* from policy manager
|
||||
|
|
@ -1476,6 +1485,20 @@ QDF_STATUS policy_mgr_register_tdls_cb(struct wlan_objmgr_psoc *psoc,
|
|||
QDF_STATUS policy_mgr_register_cdp_cb(struct wlan_objmgr_psoc *psoc,
|
||||
struct policy_mgr_cdp_cbacks *cdp_cbacks);
|
||||
|
||||
/**
|
||||
* policy_mgr_register_dp_cb() - register CDP callbacks
|
||||
* @psoc: PSOC object information
|
||||
* @cdp_cbacks: function pointers from CDP
|
||||
*
|
||||
* API, allows CDP to register callbacks to be invoked by
|
||||
* policy mgr
|
||||
*
|
||||
* Return: SUCCESS,
|
||||
* Failure (if registration fails)
|
||||
*/
|
||||
QDF_STATUS policy_mgr_register_dp_cb(struct wlan_objmgr_psoc *psoc,
|
||||
struct policy_mgr_dp_cbacks *dp_cbacks);
|
||||
|
||||
/**
|
||||
* policy_mgr_register_wma_cb() - register WMA callbacks
|
||||
* @psoc: PSOC object information
|
||||
|
|
|
|||
|
|
@ -1154,6 +1154,20 @@ void policy_mgr_incr_active_session(struct wlan_objmgr_psoc *psoc,
|
|||
if (pm_ctx->tdls_cbacks.tdls_notify_increment_session)
|
||||
pm_ctx->tdls_cbacks.tdls_notify_increment_session(psoc);
|
||||
|
||||
/*
|
||||
* Disable LRO if P2P or IBSS or SAP connection has come up or
|
||||
* there are more than one STA connections
|
||||
*/
|
||||
if ((policy_mgr_mode_specific_connection_count(psoc, PM_STA_MODE, NULL) > 1) ||
|
||||
(policy_mgr_mode_specific_connection_count(psoc, PM_SAP_MODE, NULL) > 0) ||
|
||||
(policy_mgr_mode_specific_connection_count(psoc, PM_P2P_CLIENT_MODE, NULL) >
|
||||
0) ||
|
||||
(policy_mgr_mode_specific_connection_count(psoc, PM_P2P_GO_MODE, NULL) > 0) ||
|
||||
(policy_mgr_mode_specific_connection_count(psoc, PM_IBSS_MODE, NULL) > 0)) {
|
||||
if (pm_ctx->dp_cbacks.hdd_disable_lro_in_concurrency != NULL)
|
||||
pm_ctx->dp_cbacks.hdd_disable_lro_in_concurrency(true);
|
||||
};
|
||||
|
||||
policy_mgr_dump_current_concurrency(psoc);
|
||||
|
||||
qdf_mutex_release(&pm_ctx->qdf_conc_list_lock);
|
||||
|
|
@ -1203,6 +1217,16 @@ QDF_STATUS policy_mgr_decr_active_session(struct wlan_objmgr_psoc *psoc,
|
|||
/* Notify tdls */
|
||||
if (pm_ctx->tdls_cbacks.tdls_notify_decrement_session)
|
||||
pm_ctx->tdls_cbacks.tdls_notify_decrement_session(psoc);
|
||||
/* Enable LRO if there no concurrency */
|
||||
if ((policy_mgr_mode_specific_connection_count(psoc, PM_STA_MODE, NULL) == 1) &&
|
||||
(policy_mgr_mode_specific_connection_count(psoc, PM_SAP_MODE, NULL) == 0) &&
|
||||
(policy_mgr_mode_specific_connection_count(psoc, PM_P2P_CLIENT_MODE, NULL) ==
|
||||
0) &&
|
||||
(policy_mgr_mode_specific_connection_count(psoc, PM_P2P_GO_MODE, NULL) == 0) &&
|
||||
(policy_mgr_mode_specific_connection_count(psoc, PM_IBSS_MODE, NULL) == 0)) {
|
||||
if (pm_ctx->dp_cbacks.hdd_disable_lro_in_concurrency != NULL)
|
||||
pm_ctx->dp_cbacks.hdd_disable_lro_in_concurrency(false);
|
||||
};
|
||||
|
||||
policy_mgr_dump_current_concurrency(psoc);
|
||||
|
||||
|
|
|
|||
|
|
@ -251,6 +251,7 @@ struct policy_mgr_psoc_priv_obj {
|
|||
struct policy_mgr_wma_cbacks wma_cbacks;
|
||||
struct policy_mgr_tdls_cbacks tdls_cbacks;
|
||||
struct policy_mgr_cdp_cbacks cdp_cbacks;
|
||||
struct policy_mgr_dp_cbacks dp_cbacks;
|
||||
bool enable_sap_mandatory_chan_list;
|
||||
uint8_t sap_mandatory_channels[QDF_MAX_NUM_CHAN];
|
||||
uint32_t sap_mandatory_channels_len;
|
||||
|
|
|
|||
|
|
@ -619,6 +619,23 @@ QDF_STATUS policy_mgr_register_cdp_cb(struct wlan_objmgr_psoc *psoc,
|
|||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS policy_mgr_register_dp_cb(struct wlan_objmgr_psoc *psoc,
|
||||
struct policy_mgr_dp_cbacks *dp_cbacks)
|
||||
{
|
||||
struct policy_mgr_psoc_priv_obj *pm_ctx;
|
||||
|
||||
pm_ctx = policy_mgr_get_context(psoc);
|
||||
if (!pm_ctx) {
|
||||
policy_mgr_err("Invalid Context");
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
pm_ctx->dp_cbacks.hdd_disable_lro_in_concurrency =
|
||||
dp_cbacks->hdd_disable_lro_in_concurrency;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS policy_mgr_register_tdls_cb(struct wlan_objmgr_psoc *psoc,
|
||||
struct policy_mgr_tdls_cbacks *tdls_cbacks)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue