summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/wcn36xx/wcn36xx.h
diff options
context:
space:
mode:
authorPontus Fuchs <pontus.fuchs@gmail.com>2016-04-19 08:00:44 +0300
committerKalle Valo <kvalo@qca.qualcomm.com>2016-04-25 20:37:04 +0300
commita92e4696292199714d47d8e52c4bf0318324f77f (patch)
tree963e5433a226798730b45ba61574870fd6497b1e /drivers/net/wireless/ath/wcn36xx/wcn36xx.h
parent90023c034fefe51cf67c719065434b0e43e9baf9 (diff)
downloadlinux-a92e4696292199714d47d8e52c4bf0318324f77f.tar.xz
wcn36xx: Add helper macros to cast sta to priv
While poking at this I also change two related things. I rename one variable to make the names consistent. I also move one assignment of priv_sta to the declaration to save a few lines. Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers/net/wireless/ath/wcn36xx/wcn36xx.h')
-rw-r--r--drivers/net/wireless/ath/wcn36xx/wcn36xx.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/wcn36xx/wcn36xx.h b/drivers/net/wireless/ath/wcn36xx/wcn36xx.h
index c3ba07ed1db5..c368a34c8de7 100644
--- a/drivers/net/wireless/ath/wcn36xx/wcn36xx.h
+++ b/drivers/net/wireless/ath/wcn36xx/wcn36xx.h
@@ -275,4 +275,10 @@ struct ieee80211_vif *wcn36xx_priv_to_vif(struct wcn36xx_vif *vif_priv)
return container_of((void *) vif_priv, struct ieee80211_vif, drv_priv);
}
+static inline
+struct wcn36xx_sta *wcn36xx_sta_to_priv(struct ieee80211_sta *sta)
+{
+ return (struct wcn36xx_sta *)sta->drv_priv;
+}
+
#endif /* _WCN36XX_H_ */