diff options
author | Michal Kazior <michal.kazior@tieto.com> | 2015-03-30 09:51:56 +0300 |
---|---|---|
committer | Kalle Valo <kvalo@qca.qualcomm.com> | 2015-03-30 15:09:46 +0300 |
commit | 01cebe1c50d43a79de1ee48bd9917c9fbbd3901d (patch) | |
tree | 42a3b5ab2f6736ab4fd42a661965605016761456 /drivers/net/wireless/ath/ath10k/mac.h | |
parent | 5528e032702be937acdfe8c6395461e0e8acaa85 (diff) | |
download | linux-01cebe1c50d43a79de1ee48bd9917c9fbbd3901d.tar.xz |
ath10k: deduplicate bitrate to rate idx conversion
It's possible to derive rate index from bitrate
without any additional mapping structures/logic.
This should have little to none impact on
performance since this is only done for management
frames and the previous approach wasn't
particularly optimized.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath10k/mac.h')
-rw-r--r-- | drivers/net/wireless/ath/ath10k/mac.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath10k/mac.h b/drivers/net/wireless/ath/ath10k/mac.h index af806c6f569b..a381740b8fc8 100644 --- a/drivers/net/wireless/ath/ath10k/mac.h +++ b/drivers/net/wireless/ath/ath10k/mac.h @@ -55,8 +55,11 @@ bool ath10k_mac_is_peer_wep_key_set(struct ath10k *ar, const u8 *addr, u8 keyidx); void ath10k_mac_handle_beacon(struct ath10k *ar, struct sk_buff *skb); void ath10k_mac_handle_beacon_miss(struct ath10k *ar, u32 vdev_id); + u8 ath10k_mac_hw_rate_to_idx(const struct ieee80211_supported_band *sband, u8 hw_rate); +u8 ath10k_mac_bitrate_to_idx(const struct ieee80211_supported_band *sband, + u32 bitrate); static inline struct ath10k_vif *ath10k_vif_to_arvif(struct ieee80211_vif *vif) { |