Search Linux Wireless

Re: [RESEND 9/9] ath11k: optimize ath11k_hal_tx_status_parse

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2019-12-04 11:07, John Crispin wrote:
Moving the function into dp_tx.c allows gcc to optimize the code better
and also avoid chace invalidates and context switches.

Signed-off-by: John Crispin <john@xxxxxxxxxxx>
---
 drivers/net/wireless/ath/ath11k/dp.h     |  2 +-
 drivers/net/wireless/ath/ath11k/dp_tx.c  | 38 +++++++++++++++++++--
 drivers/net/wireless/ath/ath11k/hal_tx.c | 43 ------------------------
 drivers/net/wireless/ath/ath11k/hal_tx.h |  4 ---
 4 files changed, 37 insertions(+), 50 deletions(-)

diff --git a/drivers/net/wireless/ath/ath11k/dp.h
b/drivers/net/wireless/ath/ath11k/dp.h
index d4011f902930..2f0980f2c762 100644
--- a/drivers/net/wireless/ath/ath11k/dp.h
+++ b/drivers/net/wireless/ath/ath11k/dp.h
@@ -57,7 +57,7 @@ struct dp_rxdma_ring {
 	int bufs_max;
 };

-#define ATH11K_TX_COMPL_NEXT(x)	((x + 1) % DP_TX_COMP_RING_SIZE)
+#define ATH11K_TX_COMPL_NEXT(x)	(((x) + 1) % DP_TX_COMP_RING_SIZE)

 struct dp_tx_ring {
 	u8 tcl_data_ring_id;
diff --git a/drivers/net/wireless/ath/ath11k/dp_tx.c
b/drivers/net/wireless/ath/ath11k/dp_tx.c
index 5d6403cf99ab..828f8984235e 100644
--- a/drivers/net/wireless/ath/ath11k/dp_tx.c
+++ b/drivers/net/wireless/ath/ath11k/dp_tx.c
@@ -423,6 +423,37 @@ static void ath11k_dp_tx_complete_msdu(struct ath11k *ar,
 	rcu_read_unlock();
 }

+static inline void ath11k_hal_tx_status_parse(struct ath11k_base *ab,
+					      struct hal_wbm_release_ring *desc,
+					      struct hal_tx_status *ts)

The function naming may need to be changed to be consistent with the other
functions in the file.

Vasanth



[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux