summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhqu <hqu@codeaurora.org>2017-10-10 17:52:01 +0800
committersnandini <snandini@codeaurora.org>2017-10-11 20:54:45 -0700
commit541812a05ac78bb473a7f68226ca1f5ea710ae2f (patch)
tree186591611901ba4cdd71b1c47d1b1d161a3299f1
parent0d6133962ec2eda5ab528a270baf0e39d6d7c969 (diff)
qcacld-3.0: Add device_mode check in hdd_ipa_send_pkt_to_tl
Add device_mode check in hdd_ipa_send_pkt_to_tl, WLAN_HDD_GET_AP_CTX_PTR only can be used in SAP/P2P_GO mode. Change-Id: Ieb4ce8fb28251432c9f3e22eb945b32f47776380 CRs-Fixed: 2123952
-rw-r--r--core/hdd/src/wlan_hdd_ipa.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/core/hdd/src/wlan_hdd_ipa.c b/core/hdd/src/wlan_hdd_ipa.c
index d165f2c3b6f2..7a6470a96061 100644
--- a/core/hdd/src/wlan_hdd_ipa.c
+++ b/core/hdd/src/wlan_hdd_ipa.c
@@ -4568,12 +4568,15 @@ static void hdd_ipa_send_pkt_to_tl(
* During CAC period, data packets shouldn't be sent over the air so
* drop all the packets here
*/
- if (WLAN_HDD_GET_AP_CTX_PTR(adapter)->dfs_cac_block_tx) {
- ipa_free_skb(ipa_tx_desc);
- qdf_spin_unlock_bh(&iface_context->interface_lock);
- iface_context->stats.num_tx_cac_drop++;
- hdd_ipa_rm_try_release(hdd_ipa);
- return;
+ if (QDF_SAP_MODE == adapter->device_mode ||
+ QDF_P2P_GO_MODE == adapter->device_mode) {
+ if (WLAN_HDD_GET_AP_CTX_PTR(adapter)->dfs_cac_block_tx) {
+ ipa_free_skb(ipa_tx_desc);
+ qdf_spin_unlock_bh(&iface_context->interface_lock);
+ iface_context->stats.num_tx_cac_drop++;
+ hdd_ipa_rm_try_release(hdd_ipa);
+ return;
+ }
}
++adapter->stats.tx_packets;