imx6: fix redundant PROFILES overrides in image makefile
[openwrt/openwrt.git] / package / kernel / mac80211 / patches / 310-ath10k-improve-tx-scheduling.patch
1 From: Michal Kazior <michal.kazior@tieto.com>
2 Date: Mon, 23 May 2016 23:12:45 +0300
3 Subject: [PATCH] ath10k: improve tx scheduling
4
5 Recent changes revolving around implementing
6 wake_tx_queue support introduced a significant
7 performance regressions on some (slower, uni-proc)
8 systems.
9
10 Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
11 Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
12 ---
13
14 --- a/drivers/net/wireless/ath/ath10k/htt_rx.c
15 +++ b/drivers/net/wireless/ath/ath10k/htt_rx.c
16 @@ -2291,7 +2291,6 @@ bool ath10k_htt_t2h_msg_handler(struct a
17 ath10k_htt_tx_mgmt_dec_pending(htt);
18 spin_unlock_bh(&htt->tx_lock);
19 }
20 - ath10k_mac_tx_push_pending(ar);
21 break;
22 }
23 case HTT_T2H_MSG_TYPE_TX_COMPL_IND:
24 @@ -2442,8 +2441,6 @@ static void ath10k_htt_txrx_compl_task(u
25 dev_kfree_skb_any(skb);
26 }
27
28 - ath10k_mac_tx_push_pending(ar);
29 -
30 num_mpdus = atomic_read(&htt->num_mpdus_ready);
31
32 while (num_mpdus) {
33 --- a/drivers/net/wireless/ath/ath10k/mac.c
34 +++ b/drivers/net/wireless/ath/ath10k/mac.c
35 @@ -3827,6 +3827,9 @@ void ath10k_mac_tx_push_pending(struct a
36 int ret;
37 int max;
38
39 + if (ar->htt.num_pending_tx >= (ar->htt.max_num_pending_tx / 2))
40 + return;
41 +
42 spin_lock_bh(&ar->txqs_lock);
43 rcu_read_lock();
44
45 @@ -4097,9 +4100,7 @@ static void ath10k_mac_op_wake_tx_queue(
46 list_add_tail(&artxq->list, &ar->txqs);
47 spin_unlock_bh(&ar->txqs_lock);
48
49 - if (ath10k_mac_tx_can_push(hw, txq))
50 - tasklet_schedule(&ar->htt.txrx_compl_task);
51 -
52 + ath10k_mac_tx_push_pending(ar);
53 ath10k_htt_tx_txq_update(hw, txq);
54 }
55
56 --- a/drivers/net/wireless/ath/ath10k/txrx.c
57 +++ b/drivers/net/wireless/ath/ath10k/txrx.c
58 @@ -117,6 +117,9 @@ int ath10k_txrx_tx_unref(struct ath10k_h
59
60 ieee80211_tx_status(htt->ar->hw, msdu);
61 /* we do not own the msdu anymore */
62 +
63 + ath10k_mac_tx_push_pending(ar);
64 +
65 return 0;
66 }
67