Commit 56ac13bf authored by Amadeusz Sławiński's avatar Amadeusz Sławiński Committed by Kalle Valo

ath10k: remove ath10k_vif_to_arvif()

it adds unnecessary level of indirection, while we just access structure
field
Signed-off-by: default avatarAmadeusz Sławiński <amadeusz.slawinski@tieto.com>
Signed-off-by: default avatarKalle Valo <kvalo@qca.qualcomm.com>
parent 3b03cc07
This diff is collapsed.
...@@ -83,17 +83,12 @@ struct ieee80211_txq *ath10k_mac_txq_lookup(struct ath10k *ar, ...@@ -83,17 +83,12 @@ struct ieee80211_txq *ath10k_mac_txq_lookup(struct ath10k *ar,
u8 tid); u8 tid);
int ath10k_mac_ext_resource_config(struct ath10k *ar, u32 val); int ath10k_mac_ext_resource_config(struct ath10k *ar, u32 val);
static inline struct ath10k_vif *ath10k_vif_to_arvif(struct ieee80211_vif *vif)
{
return (struct ath10k_vif *)vif->drv_priv;
}
static inline void ath10k_tx_h_seq_no(struct ieee80211_vif *vif, static inline void ath10k_tx_h_seq_no(struct ieee80211_vif *vif,
struct sk_buff *skb) struct sk_buff *skb)
{ {
struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data;
struct ath10k_vif *arvif = ath10k_vif_to_arvif(vif); struct ath10k_vif *arvif = (void *)vif->drv_priv;
if (info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ) { if (info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ) {
if (arvif->tx_seq_no == 0) if (arvif->tx_seq_no == 0)
......
...@@ -132,7 +132,7 @@ struct ath10k_p2p_noa_arg { ...@@ -132,7 +132,7 @@ struct ath10k_p2p_noa_arg {
static void ath10k_p2p_noa_update_vdev_iter(void *data, u8 *mac, static void ath10k_p2p_noa_update_vdev_iter(void *data, u8 *mac,
struct ieee80211_vif *vif) struct ieee80211_vif *vif)
{ {
struct ath10k_vif *arvif = ath10k_vif_to_arvif(vif); struct ath10k_vif *arvif = (void *)vif->drv_priv;
struct ath10k_p2p_noa_arg *arg = data; struct ath10k_p2p_noa_arg *arg = data;
if (arvif->vdev_id != arg->vdev_id) if (arvif->vdev_id != arg->vdev_id)
......
...@@ -1779,7 +1779,7 @@ static void ath10k_wmi_tx_beacon_nowait(struct ath10k_vif *arvif) ...@@ -1779,7 +1779,7 @@ static void ath10k_wmi_tx_beacon_nowait(struct ath10k_vif *arvif)
static void ath10k_wmi_tx_beacons_iter(void *data, u8 *mac, static void ath10k_wmi_tx_beacons_iter(void *data, u8 *mac,
struct ieee80211_vif *vif) struct ieee80211_vif *vif)
{ {
struct ath10k_vif *arvif = ath10k_vif_to_arvif(vif); struct ath10k_vif *arvif = (void *)vif->drv_priv;
ath10k_wmi_tx_beacon_nowait(arvif); ath10k_wmi_tx_beacon_nowait(arvif);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment