source: trunk/package/mac80211/patches/411-ath5k_allow_adhoc_and_ap.patch @ 31322

Last change on this file since 31322 was 31322, checked in by nbd, 5 years ago

mac80211: update to wireless-testing 2012-04-13

File size: 1.8 KB
  • drivers/net/wireless/ath/ath5k/mac80211-ops.c

    a b ath5k_add_interface(struct ieee80211_hw  
    8686                goto end; 
    8787        } 
    8888 
    89         /* Don't allow other interfaces if one ad-hoc is configured. 
    90          * TODO: Fix the problems with ad-hoc and multiple other interfaces. 
    91          * We would need to operate the HW in ad-hoc mode to allow TSF updates 
    92          * for the IBSS, but this breaks with additional AP or STA interfaces 
    93          * at the moment. */ 
    94         if (ah->num_adhoc_vifs || 
    95             (ah->nvifs && vif->type == NL80211_IFTYPE_ADHOC)) { 
     89        /* Don't allow more than one ad-hoc interface */ 
     90        if (ah->num_adhoc_vifs && vif->type == NL80211_IFTYPE_ADHOC) { 
    9691                ATH5K_ERR(ah, "Only one single ad-hoc interface is allowed.\n"); 
    9792                ret = -ELNRNG; 
    9893                goto end; 
  • drivers/net/wireless/ath/ath5k/base.c

    a b ath5k_beacon_send(struct ath5k_hw *ah) 
    18711871        } 
    18721872 
    18731873        if ((ah->opmode == NL80211_IFTYPE_AP && ah->num_ap_vifs + 
    1874                         ah->num_mesh_vifs > 1) || 
     1874                        ah->num_adhoc_vifs + ah->num_mesh_vifs > 1) || 
    18751875                        ah->opmode == NL80211_IFTYPE_MESH_POINT) { 
    18761876                u64 tsf = ath5k_hw_get_tsf64(ah); 
    18771877                u32 tsftu = TSF_TO_TU(tsf); 
    ath5k_beacon_update_timers(struct ath5k_ 
    19571957 
    19581958        intval = ah->bintval & AR5K_BEACON_PERIOD; 
    19591959        if (ah->opmode == NL80211_IFTYPE_AP && ah->num_ap_vifs 
    1960                 + ah->num_mesh_vifs > 1) { 
     1960                + ah->num_adhoc_vifs + ah->num_mesh_vifs > 1) { 
    19611961                intval /= ATH_BCBUF;    /* staggered multi-bss beacons */ 
    19621962                if (intval < 15) 
    19631963                        ATH5K_WARN(ah, "intval %u is too low, min 15\n", 
    ath5k_tx_complete_poll_work(struct work_ 
    24192419static const struct ieee80211_iface_limit if_limits[] = { 
    24202420        { .max = 256,   .types = BIT(NL80211_IFTYPE_STATION) }, 
    24212421        { .max = 4,     .types = BIT(NL80211_IFTYPE_AP) | 
     2422                                 BIT(NL80211_IFTYPE_ADHOC) | 
    24222423                                 BIT(NL80211_IFTYPE_MESH_POINT) }, 
    24232424}; 
    24242425 
Note: See TracBrowser for help on using the repository browser.