1. 26 Nov, 2012 2 commits
    • Johannes Berg's avatar
      mac80211: convert to channel definition struct · 4bf88530
      Johannes Berg authored
      
      
      Convert mac80211 (and where necessary, some drivers a
      little bit) to the new channel definition struct.
      
      This will allow extending mac80211 for VHT, which is
      currently restricted to channel contexts since there
      are no drivers using that which makes it easier. As
      I also don't care about VHT for drivers not using the
      channel context API, I won't convert the previous API
      to VHT support.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      4bf88530
    • Johannes Berg's avatar
      cfg80211: remove remain-on-channel channel type · 42d97a59
      Johannes Berg authored
      
      
      As mwifiex (and mac80211 in the software case) are the
      only drivers actually implementing remain-on-channel
      with channel type, userspace can't be relying on it.
      This is the case, as it's used only for P2P operations
      right now.
      
      Rather than adding a flag to tell userspace whether or
      not it can actually rely on it, simplify all the code
      by removing the ability to use different channel types.
      Leave only the validation of the attribute, so that if
      we extend it again later (with the needed capability
      flag), it can't break userspace sending invalid data.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      42d97a59
  2. 21 Nov, 2012 1 commit
  3. 19 Nov, 2012 2 commits
  4. 13 Nov, 2012 1 commit
  5. 09 Nov, 2012 2 commits
    • Johannes Berg's avatar
      mac80211: clarify interface iteration and make it configurable · 8b2c9824
      Johannes Berg authored
      
      
      During hardware restart, all interfaces are iterated even
      though they haven't been re-added to the driver, document
      this behaviour. The same also happens during resume, which
      is even more confusing since all of the interfaces were
      previously removed from the driver. Make this optional so
      drivers relying on the current behaviour can still use it,
      but to let drivers that don't want this behaviour disable
      it.
      
      Also convert all API users, keeping the old semantics
      except in hwsim, where the new normal ones are desired.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      8b2c9824
    • Johannes Berg's avatar
      mac80211: call driver method when restart completes · 9214ad7f
      Johannes Berg authored
      
      
      When the driver requests a restart (reconfiguration) it
      gets all the normal method calls, but can't really tell
      why they're happening. Call a new restart_complete op
      in the driver when the restart completes, so it could
      keep its own state about the restart and clear it there.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      9214ad7f
  6. 06 Nov, 2012 1 commit
  7. 30 Oct, 2012 1 commit
    • Johannes Berg's avatar
      mac80211: handle TX power per virtual interface · 1ea6f9c0
      Johannes Berg authored
      
      
      Even before channel contexts/multi-channel, having a
      single global TX power limit was already problematic,
      in particular if two managed interfaces connected to
      two APs with different power constraints. The channel
      context introduction completely broke this though and
      in fact I had disabled TX power configuration there
      for drivers using channel contexts.
      
      Change everything to track TX power per interface so
      that different user settings and different channel
      maxima are treated correctly. Also continue tracking
      the global TX power though for compatibility with
      applications that attempt to configure the wiphy's
      TX power globally.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      1ea6f9c0
  8. 26 Oct, 2012 1 commit
  9. 23 Oct, 2012 1 commit
  10. 18 Oct, 2012 1 commit
  11. 17 Oct, 2012 3 commits
  12. 16 Oct, 2012 2 commits
  13. 10 Sep, 2012 1 commit
    • Johannes Berg's avatar
      mac80211: add key flag for management keys · e548c49e
      Johannes Berg authored
      
      
      Mark keys that might be used to receive management
      frames so drivers can fall back on software crypto
      for them if they don't support hardware offload.
      As the new flag is only set correctly for RX keys
      and the existing IEEE80211_KEY_FLAG_SW_MGMT flag
      can only affect TX, also rename the latter to
      IEEE80211_KEY_FLAG_SW_MGMT_TX.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      e548c49e
  14. 20 Aug, 2012 3 commits
  15. 31 Jul, 2012 2 commits
    • Thomas Huehn's avatar
      mac80211: move TX station pointer and restructure TX · 36323f81
      Thomas Huehn authored
      
      
      Remove the control.sta pointer from ieee80211_tx_info to free up
      sufficient space in the TX skb control buffer for the upcoming
      Transmit Power Control (TPC).
      Instead, the pointer is now on the stack in a new control struct
      that is passed as a function parameter to the drivers' tx method.
      Signed-off-by: default avatarThomas Huehn <thomas@net.t-labs.tu-berlin.de>
      Signed-off-by: default avatarAlina Friedrichsen <x-alina@gmx.net>
      Signed-off-by: default avatarFelix Fietkau <nbd@openwrt.org>
      [reworded commit message]
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      36323f81
    • Eliad Peller's avatar
      mac80211: add PS flag to bss_conf · ab095877
      Eliad Peller authored
      
      
      Currently, ps mode is indicated per device (rather than
      per interface), which doesn't make a lot of sense.
      
      Moreover, there are subtle bugs caused by the inability
      to indicate ps change along with other changes
      (e.g. when the AP deauth us, we'd like to indicate
      CHANGED_PS | CHANGED_ASSOC, as changing PS before
      notifying about disassociation will result in null-packets
      being sent (if IEEE80211_HW_SUPPORTS_DYNAMIC_PS) while
      the sta is already disconnected.)
      
      Keep the current per-device notifications, and add
      parallel per-vif notifications.
      
      In order to keep it simple, the per-device ps and
      the per-vif ps are orthogonal - the per-vif ps
      configuration is determined only by the user
      configuration (enable/disable) and the connection
      state, and is not affected by other vifs state and
      (temporary) dynamic_ps/offchannel operations
      (unlike per-device ps).
      Signed-off-by: default avatarEliad Peller <eliad@wizery.com>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      ab095877
  16. 12 Jul, 2012 2 commits
    • Johannes Berg's avatar
      mac80211: add time synchronisation with BSS for assoc · 8c358bcd
      Johannes Berg authored
      
      
      Some drivers (iwlegacy, iwlwifi and rt2x00) today use the
      bss_conf.last_tsf value. By itself though that value is
      completely worthless since it may be ancient. What really
      is needed is synchronisation between some device time and
      the TSF.
      
      To clarify this, rename bss_conf.last_tsf to sync_tsf and
      add sync_device_ts which is obtained from rx_status which
      gets a new field device_timestamp for this purpose. This
      is intentionally not using the mactime field since that
      is used for other things and in IBSS is expected to sync
      with the IBSS's TSF which isn't necessarily true for the
      device timestamp.
      
      Also, since we have the information and it's useful even
      before the connection has been established, give all the
      timing details to the driver before authenticating.
      Reviewed-by: default avatarEmmanuel Grumbach <emmanuel.grumbach@intel.com>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      8c358bcd
    • Johannes Berg's avatar
      mac80211: optimize ieee80211_rx_status struct layout · 30f42292
      Johannes Berg authored
      
      
      We waste a lot of space in this struct because it uses
      int values where smaller ones would be sufficient. The
      upcoming A-MPDU information needs some space, optimize
      the struct now.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      30f42292
  17. 09 Jul, 2012 1 commit
  18. 03 Jul, 2012 2 commits
  19. 02 Jul, 2012 1 commit
  20. 28 Jun, 2012 1 commit
  21. 24 Jun, 2012 1 commit
    • Johannes Berg's avatar
      mac80211: clean up debugging · bdcbd8e0
      Johannes Berg authored
      
      
      There are a few things that make the logging and
      debugging in mac80211 less useful than it should
      be right now:
       * a lot of messages should be pr_info, not pr_debug
       * wholesale use of pr_debug makes it require *both*
         Kconfig and dynamic configuration
       * there are still a lot of ifdefs
       * the style is very inconsistent, sometimes the
         sdata->name is printed in front
      
      Clean up everything, introducing new macros and
      separating out the station MLME debugging into
      a new Kconfig symbol.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      bdcbd8e0
  22. 21 Jun, 2012 1 commit
  23. 09 Jun, 2012 1 commit
  24. 06 Jun, 2012 2 commits
    • Johannes Berg's avatar
      mac80211: unify SW/offload remain-on-channel · 2eb278e0
      Johannes Berg authored
      
      
      Redesign all the off-channel code, getting rid of
      the generic off-channel work concept, replacing
      it with a simple remain-on-channel list.
      
      This fixes a number of small issues with the ROC
      implementation:
       * offloaded remain-on-channel couldn't be queued,
         now we can queue it as well, if needed
       * in iwlwifi (the only user) offloaded ROC is
         mutually exclusive with scanning, use the new
         queue to handle that case -- I expect that it
         will later depend on a HW flag
      
      The bigger issue though is that there's a bad bug
      in the current implementation: if we get a mgmt
      TX request while HW roc is active, and this new
      request has a wait time, we actually schedule a
      software ROC instead since we can't guarantee the
      existing offloaded ROC will still be that long.
      To fix this, the queuing mechanism was needed.
      
      The queuing mechanism for offloaded ROC isn't yet
      optimal, ideally we should add API to have the HW
      extend the ROC if needed. We could add that later
      but for now use a software implementation.
      
      Overall, this unifies the behaviour between the
      offloaded and software-implemented case as much
      as possible.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      2eb278e0
    • Johannes Berg's avatar
      mac80211: do remain-on-channel while idle · 196ac1c1
      Johannes Berg authored
      
      
      The IDLE handling in HW off-channel is broken right
      now since we turn off IDLE only when the off-channel
      period already started. Therefore, all drivers that
      use it today (only iwlwifi!) must support off-channel
      while idle, so playing with idle isn't needed at all.
      
      Off-channel in general, since it's no longer used for
      authentication/association, shouldn't affect PS, so
      also remove that logic.
      
      Also document a small caveat for reporting TX status
      from off-channel frames in HW remain-on-channel.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      196ac1c1
  25. 05 Jun, 2012 4 commits