diff options
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/beacon.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/beacon.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/drivers/net/wireless/ath/ath9k/beacon.c b/drivers/net/wireless/ath/ath9k/beacon.c index 385ba03134ba..8de591e5b851 100644 --- a/drivers/net/wireless/ath/ath9k/beacon.c +++ b/drivers/net/wireless/ath/ath9k/beacon.c | |||
@@ -244,9 +244,7 @@ int ath_beacon_alloc(struct ath_wiphy *aphy, struct ieee80211_vif *vif) | |||
244 | struct ath_buf, list); | 244 | struct ath_buf, list); |
245 | list_del(&avp->av_bcbuf->list); | 245 | list_del(&avp->av_bcbuf->list); |
246 | 246 | ||
247 | if (sc->sc_ah->opmode == NL80211_IFTYPE_AP || | 247 | if (ath9k_uses_beacons(vif->type)) { |
248 | sc->sc_ah->opmode == NL80211_IFTYPE_ADHOC || | ||
249 | sc->sc_ah->opmode == NL80211_IFTYPE_MESH_POINT) { | ||
250 | int slot; | 248 | int slot; |
251 | /* | 249 | /* |
252 | * Assign the vif to a beacon xmit slot. As | 250 | * Assign the vif to a beacon xmit slot. As |
@@ -282,7 +280,7 @@ int ath_beacon_alloc(struct ath_wiphy *aphy, struct ieee80211_vif *vif) | |||
282 | /* NB: the beacon data buffer must be 32-bit aligned. */ | 280 | /* NB: the beacon data buffer must be 32-bit aligned. */ |
283 | skb = ieee80211_beacon_get(sc->hw, vif); | 281 | skb = ieee80211_beacon_get(sc->hw, vif); |
284 | if (skb == NULL) { | 282 | if (skb == NULL) { |
285 | ath_dbg(common, ATH_DBG_BEACON, "cannot get skb\n"); | 283 | ath_err(common, "ieee80211_beacon_get failed\n"); |
286 | return -ENOMEM; | 284 | return -ENOMEM; |
287 | } | 285 | } |
288 | 286 | ||
@@ -720,10 +718,10 @@ void ath_beacon_config(struct ath_softc *sc, struct ieee80211_vif *vif) | |||
720 | iftype = sc->sc_ah->opmode; | 718 | iftype = sc->sc_ah->opmode; |
721 | } | 719 | } |
722 | 720 | ||
723 | cur_conf->listen_interval = 1; | 721 | cur_conf->listen_interval = 1; |
724 | cur_conf->dtim_count = 1; | 722 | cur_conf->dtim_count = 1; |
725 | cur_conf->bmiss_timeout = | 723 | cur_conf->bmiss_timeout = |
726 | ATH_DEFAULT_BMISS_LIMIT * cur_conf->beacon_interval; | 724 | ATH_DEFAULT_BMISS_LIMIT * cur_conf->beacon_interval; |
727 | 725 | ||
728 | /* | 726 | /* |
729 | * It looks like mac80211 may end up using beacon interval of zero in | 727 | * It looks like mac80211 may end up using beacon interval of zero in |