summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath9k/ath9k.h
diff options
context:
space:
mode:
authorSujith Manoharan <c_manoha@qca.qualcomm.com>2014-08-23 19:12:16 +0530
committerJohn W. Linville <linville@tuxdriver.com>2014-08-28 14:49:38 -0400
commit6e47fafbc38a93797f86413db8eea3e9319ebbd0 (patch)
tree0189c9a65dd95786cb626776c545d5b45b80ac1d /drivers/net/wireless/ath/ath9k/ath9k.h
parent11e39a4e054cde1aaa9f5d3830f41f86818602fd (diff)
downloadlinux-6e47fafbc38a93797f86413db8eea3e9319ebbd0.tar.gz
linux-6e47fafbc38a93797f86413db8eea3e9319ebbd0.tar.bz2
linux-6e47fafbc38a93797f86413db8eea3e9319ebbd0.zip
ath9k: Fix ath_chanctx_get()
Move it inside a CONFIG_ATH9K_CHANNEL_CONTEXT ifdef since it is not needed otherwise. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/ath9k.h')
-rw-r--r--drivers/net/wireless/ath/ath9k/ath9k.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/drivers/net/wireless/ath/ath9k/ath9k.h b/drivers/net/wireless/ath/ath9k/ath9k.h
index 9e61679b3de2..acbe2b7956ae 100644
--- a/drivers/net/wireless/ath/ath9k/ath9k.h
+++ b/drivers/net/wireless/ath/ath9k/ath9k.h
@@ -413,16 +413,19 @@ struct ath_offchannel {
ctx <= &sc->chanctx[ARRAY_SIZE(sc->chanctx) - 1]; \
ctx++)
+void ath_chanctx_init(struct ath_softc *sc);
+void ath_chanctx_set_channel(struct ath_softc *sc, struct ath_chanctx *ctx,
+ struct cfg80211_chan_def *chandef);
+
+#ifdef CONFIG_ATH9K_CHANNEL_CONTEXT
+
static inline struct ath_chanctx *
ath_chanctx_get(struct ieee80211_chanctx_conf *ctx)
{
struct ath_chanctx **ptr = (void *) ctx->drv_priv;
return *ptr;
}
-void ath_chanctx_init(struct ath_softc *sc);
-void ath_chanctx_set_channel(struct ath_softc *sc, struct ath_chanctx *ctx,
- struct cfg80211_chan_def *chandef);
-#ifdef CONFIG_ATH9K_CHANNEL_CONTEXT
+
bool ath9k_is_chanctx_enabled(void);
void ath9k_fill_chanctx_ops(void);
void ath9k_init_channel_context(struct ath_softc *sc);
@@ -451,7 +454,9 @@ void ath_chanctx_set_next(struct ath_softc *sc, bool force);
void ath_offchannel_next(struct ath_softc *sc);
void ath_scan_complete(struct ath_softc *sc, bool abort);
void ath_roc_complete(struct ath_softc *sc, bool abort);
+
#else
+
static inline bool ath9k_is_chanctx_enabled(void)
{
return false;
@@ -513,6 +518,7 @@ static inline void ath_chanctx_check_active(struct ath_softc *sc,
struct ath_chanctx *ctx)
{
}
+
#endif /* CONFIG_ATH9K_CHANNEL_CONTEXT */
int ath_reset_internal(struct ath_softc *sc, struct ath9k_channel *hchan);