1. 13 May, 2009 1 commit
    • Jouni Malinen's avatar
      nl80211: Add IEEE 802.1X PAE control for station mode · 3f77316c
      Jouni Malinen authored
      
      
      Add a new NL80211_ATTR_CONTROL_PORT flag for NL80211_CMD_ASSOCIATE to
      allow user space to indicate that it will control the IEEE 802.1X port
      in station mode. Previously, mac80211 was always marking the port
      authorized in station mode. This was enough when drop_unencrypted flag
      was set. However, drop_unencrypted can currently be controlled only
      with WEXT and the current nl80211 design does not allow fully secure
      configuration. Fix this by providing a mechanism for user space to
      control the IEEE 802.1X port in station mode (i.e., do the same that
      we are already doing in AP mode).
      Signed-off-by: default avatarJouni Malinen <jouni.malinen@atheros.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      3f77316c
  2. 11 May, 2009 1 commit
  3. 06 May, 2009 4 commits
    • Johannes Berg's avatar
      mac80211: tell driver when idle · 5cff20e6
      Johannes Berg authored
      
      
      When we aren't doing anything in mac80211, we can turn off
      much of the hardware, depending on the driver/hw. Not doing
      anything, aka being idle, means:
      
       * no monitor interfaces
       * no AP/mesh/wds interfaces
       * any station interfaces are in DISABLED state
       * any IBSS interfaces aren't trying to be in a network
       * we aren't trying to scan
      
      By creating a new function that verifies these conditions and calling
      it at strategic points where the states of those conditions change,
      we can easily make mac80211 tell the driver when we are idle to save
      power.
      
      Additionally, this fixes a small quirk where a recalculated powersave
      state is passed to the driver even if the hardware is about to stopped
      completely.
      
      This patch intentionally doesn't touch radio_enabled because that is
      currently implemented to be a soft rfkill which is inappropriate here
      when we need to be able to wake up with low latency.
      
      One thing I'm not entirely sure about is this:
      
        phy0: device no longer idle - in use
        wlan0: direct probe to AP 00:11:24:91:07:4d try 1
        wlan0 direct probe responded
        wlan0: authenticate with AP 00:11:24:91:07:4d
        wlan0: authenticated
      > phy0: device now idle
      > phy0: device no longer idle - in use
        wlan0: associate with AP 00:11:24:91:07:4d
        wlan0: RX AssocResp from 00:11:24:91:07:4d (capab=0x401 status=0 aid=1)
        wlan0: associated
      
      Is it appropriate to go into idle state for a short time when we have
      just authenticated, but not associated yet? This happens only with the
      userspace SME, because we cannot really know how long it will wait
      before asking us to associate. Would going idle after a short timeout
      be more appropriate? We may need to revisit this, depending on what
      happens.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      5cff20e6
    • Johannes Berg's avatar
      mac80211: fix probe response processing · 16cf438a
      Johannes Berg authored
      
      
      Due to the use of a _REQ_DIRECT_PROBE bit, which is
      unnecessary (and I wonder why it was done that way),
      an interesting situation can arise:
       1) we try to probe an access point
       2) the AP doesn't response in time
       3) we tell userspace that we gave up
       4) the AP suddenly responds
       5) we auth/assoc with the AP
      
      I've seen 4) happen in testing with hostapd SIGSTOPped,
      and when SIGCONTinued it processes the probe requests
      that came in and send responses. But 5) is not supposed
      to happen after we tell everybody we've given up on the
      AP.
      
      To fix this, remove the _REQ_DIRECT_PROBE request bit,
      and process probe responses when we're in the relevant
      MLME state, namely IEEE80211_STA_MLME_DIRECT_PROBE.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      16cf438a
    • Johannes Berg's avatar
      mac80211: unify config_interface and bss_info_changed · 2d0ddec5
      Johannes Berg authored
      
      
      The config_interface method is a little strange, it contains the
      BSSID and beacon updates, while bss_info_changed contains most
      other BSS information for each interface. This patch removes
      config_interface and rolls all the information it previously
      passed to drivers into bss_info_changed.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      2d0ddec5
    • Johannes Berg's avatar
      mac80211: fix scan races and rework scanning · f3b85252
      Johannes Berg authored
      
      
      There are some places marked
      	/* XXX maybe racy? */
      and they really are racy because there's no locking.
      
      This patch reworks much of the scan code, and introduces proper
      locking for the scan request as well as the internal scanning
      (which is necessary for IBSS/managed modes). Helper functions
      are added to call the scanning code whenever necessary. The
      scan deferring is changed to simply queue the scanning work
      instead of trying to start the scan in place, the scanning work
      will then take care of the rest.
      
      Also, currently when internal scans are requested for an interface
      that is trying to associate, we reject such scans. This was not
      intended, the mlme code has provisions to scan twice when it can't
      find the BSS to associate with right away; this has never worked
      properly. Fix this by not rejecting internal scan requests for an
      interface that is associating.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      f3b85252
  4. 22 Apr, 2009 11 commits
    • Johannes Berg's avatar
      mac80211: validate TIM IE length (redux) · e7ec86f5
      Johannes Berg authored
      
      
      The TIM IE must not be shorter than 4 bytes, so verify that
      when parsing it and use the proper type. To ease that adjust
      struct ieee80211_tim_ie to have a virtual bitmap of size
      at least 1.
      
      Also check that the TIM IE is actually present before trying
      to parse it!
      
      Because other people may need the function, make it a static
      inline in ieee80211.h.
      
      (The original "mac80211: validate TIM IE length" was a minimal fix for
      2.6.30.  This purports to be the full, correct fix. -- JWL)
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      e7ec86f5
    • Jouni Malinen's avatar
      nl80211: Add set/get for frag/rts threshold and retry limits · b9a5f8ca
      Jouni Malinen authored
      
      
      Add new nl80211 attributes that can be used with NL80211_CMD_SET_WIPHY
      and NL80211_CMD_GET_WIPHY to manage fragmentation/RTS threshold and
      retry limits.
      
      Since these values are stored in struct wiphy, remove the local copy
      from mac80211 where feasible (frag & rts threshold). The retry limits
      are currently needed in struct ieee80211_conf, but these could be
      eventually removed since the driver should have access to the values
      in struct wiphy.
      Signed-off-by: default avatarJouni Malinen <j@w1.fi>
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      b9a5f8ca
    • Johannes Berg's avatar
      cfg80211: clean up includes · d3236553
      Johannes Berg authored
      
      
      Trying to separate header files into net/wireless.h and
      net/cfg80211.h has been a source of confusion. Remove
      net/wireless.h (because there also is the linux/wireless.h)
      and subsume everything into net/cfg80211.h -- except the
      definitions for regulatory structures which get moved to
      a new header net/regulatory.h.
      
      The "new" net/cfg80211.h is now divided into sections.
      
      There are no real changes in this patch but code shuffling
      and some very minor documentation fixes.
      
      I have also, to make things reflect reality, put in a
      copyright line for Luis to net/regulatory.h since that
      is probably exclusively written by him but was formerly
      in a file that only had my copyright line.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Cc: Luis R. Rodriguez <lrodriguez@atheros.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      d3236553
    • Johannes Berg's avatar
      mac80211: convert to cfg80211 IBSS API · af8cdcd8
      Johannes Berg authored
      
      
      This converts mac80211 to the new cfg80211 IBSS API, the
      wext handling functions are called where appropriate.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      af8cdcd8
    • Johannes Berg's avatar
      mac80211: implement beacon filtering in software · d91f36db
      Johannes Berg authored
      
      
      Regardless of whether the hardware implements beacon filtering,
      there's no need to process all beacons in software all the time
      throughout the stack (mac80211 does a lot, then cfg80211, then
      in the future possibly userspace).
      
      This patch implements the "best possible" beacon filtering in
      mac80211. "Best possible" means that it can look for changes in
      all requested information elements, and distinguish vendor IEs
      by their OUI.
      
      In the future, we will add nl80211 API for userspace to request
      information elements and vendor IE OUIs to watch -- drivers can
      then implement the best they can do while software implements
      it fully.
      
      It is unclear whether or not this actually saves CPU time, but
      the data is all in the cache already so it should be fairly
      cheap. The additional _testing_, however, has great benefit;
      Without this, and on hardware that doesn't implement beacon
      filtering, wrong assumptions about, for example, scan result
      updates could quickly creep into code.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      d91f36db
    • Johannes Berg's avatar
      mac80211: disable powersave if pm_qos asks for low latency · 10f644a4
      Johannes Berg authored
      
      
      When an application asks for a latency lower than the beacon interval
      there's nothing we can do -- we need to stay awake and not have the
      AP buffer frames for us. Add code to automatically calculate this
      constraint in mac80211 so drivers need not concern themselves with it.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      10f644a4
    • Johannes Berg's avatar
      mac80211: improve powersave implementation · 965bedad
      Johannes Berg authored
      
      
      When you have multiple virtual interfaces the current
      implementation requires setting them up properly from
      userspace, which is undesirable when we want to default
      to power save mode. Keep track of powersave requested
      from userspace per managed mode interface, and only
      enable powersave globally when exactly one managed mode
      interface is active and has powersave turned on.
      
      Second, only start the dynPS timer when PS is turned
      on, and properly turn it off when PS is turned off.
      
      Third, fix the scan_sdata abuse in the dynps code.
      
      Finally, also reorder the code and refactor the code
      that enables PS or the dynps timer instead of having
      it copied in two places.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      965bedad
    • Johannes Berg's avatar
      mac80211: add hardware restart function · f2753ddb
      Johannes Berg authored
      
      
      Some hardware defects may require the hardware to be re-initialised
      completely from scratch. Drivers would need much information (for
      instance the current MAC address, crypto keys, beaconing information,
      etc.) stored duplicated from mac80211 to be able to do this, so let
      mac80211 help them.
      
      The new ieee80211_restart_hw() function requires the same code as
      resuming, so move that code into a new ieee80211_reconfig() function
      in util.c and leave only the suspend code in pm.c.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      f2753ddb
    • Johannes Berg's avatar
      mac80211: pass all probe request IEs to driver · de95a54b
      Johannes Berg authored
      
      
      Instead of just passing the cfg80211-requested IEs, pass
      the locally generated ones as well.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      de95a54b
    • Johannes Berg's avatar
      mac80211: move ieee80211_enable_ht function to mlme.c · d5522e03
      Johannes Berg authored
      
      
      It really belongs into that file since it is only relevant
      for managed mode. Move 1:1, not even whitespace changes,
      but make it static and remove from header file.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      d5522e03
    • Jouni Malinen's avatar
      nl80211: Add Michael MIC failure event · a3b8b056
      Jouni Malinen authored
      
      
      Define a new nl80211 event, NL80211_CMD_MICHAEL_MIC_FAILURE, to be
      used to notify user space about locally detected Michael MIC failures.
      This matches with the MLME-MICHAELMICFAILURE.indication() primitive.
      
      Since we do not actually have TSC in the skb anymore when
      mac80211_ev_michael_mic_failure() is called, that function is changed
      to take in the TSC as an optional parameter instead of as a
      requirement to include the TSC after the hdr field (which we did not
      really follow). For now, TSC is not included in the events from
      mac80211, but it could be added at some point.
      Signed-off-by: default avatarJouni Malinen <j@w1.fi>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      a3b8b056
  5. 28 Mar, 2009 12 commits
    • Johannes Berg's avatar
      mac80211/iwlwifi: move virtual A-MDPU queue bookkeeping to iwlwifi · e4e72fb4
      Johannes Berg authored
      
      
      This patch removes all the virtual A-MPDU-queue bookkeeping from
      mac80211. Curiously, iwlwifi already does its own bookkeeping, so
      it doesn't require much changes except where it needs to handle
      starting and stopping the queues in mac80211.
      
      To handle the queue stop/wake properly, we rewrite the software
      queue number for aggregation frames and internally to iwlwifi keep
      track of the queues that map into the same AC queue, and only talk
      to mac80211 about the AC queue. The implementation requires calling
      two new functions, iwl_stop_queue and iwl_wake_queue instead of the
      mac80211 counterparts.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Cc: Reinette Chattre <reinette.chatre@intel.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      e4e72fb4
    • Johannes Berg's avatar
      mac80211: fix aggregation to not require queue stop · cd8ffc80
      Johannes Berg authored
      
      
      Instead of stopping the entire AC queue when enabling aggregation
      (which was only done for hardware with aggregation queues) buffer
      the packets for each station, and release them to the pending skb
      queue once aggregation is turned on successfully.
      
      We get a little more code, but it becomes conceptually simpler and
      we can remove the entire virtual queue mechanism from mac80211 in
      a follow-up patch.
      
      This changes how mac80211 behaves towards drivers that support
      aggregation but have no hardware queues -- those drivers will now
      not be handed packets while the aggregation session is being
      established, but only after it has been fully established.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      cd8ffc80
    • Johannes Berg's avatar
      mac80211: rework the pending packets code · 2a577d98
      Johannes Berg authored
      
      
      The pending packets code is quite incomprehensible, uses memory barriers
      nobody really understands, etc. This patch reworks it entirely, using
      the queue spinlock, proper stop bits and the skb queues themselves to
      indicate whether packets are pending or not (rather than a separate
      variable like before).
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Reviewed-by: default avatarLuis R. Rodriguez <lrodriguez@atheros.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      2a577d98
    • Johannes Berg's avatar
      mac80211: rewrite fragmentation · 2de8e0d9
      Johannes Berg authored
      
      
      Fragmentation currently uses an allocated array to store the
      fragment skbs, and then keeps track of which have been sent
      and which are still pending etc. This is rather complicated;
      make it simpler by just chaining the fragments into skb->next
      and removing from that list when sent. Also simplifies all
      code that needs to touch fragments, since it now only needs
      to walk the skb->next list.
      
      This is a prerequisite for fixing the stored packet code,
      which I need to do for proper aggregation packet storing.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Reviewed-by: default avatarLuis R. Rodriguez <lrodriguez@atheros.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      2de8e0d9
    • Kalle Valo's avatar
      mac80211: add beacon filtering support · 04de8381
      Kalle Valo authored
      
      
      Add IEEE80211_HW_BEACON_FILTERING flag so that driver inform that it supports
      beacon filtering. Drivers need to call the new function
      ieee80211_beacon_loss() to notify about beacon loss.
      Signed-off-by: default avatarKalle Valo <kalle.valo@nokia.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      04de8381
    • Kalle Valo's avatar
      mac80211: track beacons separately from the rx path activity · 15b7b062
      Kalle Valo authored
      
      
      Separate beacon and rx path tracking in preparation for the beacon filtering
      support. At the same time change ieee80211_associated() to look a bit simpler.
      
      Probe requests are now sent only after IEEE80211_PROBE_IDLE_TIME, which
      is now set to 60 seconds.
      Signed-off-by: default avatarKalle Valo <kalle.valo@nokia.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      15b7b062
    • Kalle Valo's avatar
      mac80211: decrease execution of the associated timer · 3cf335d5
      Kalle Valo authored
      
      
      Currently the timer is triggering every two seconds
      (IEEE80211_MONITORING_INTERVAL). Decrease the timer to only trigger during
      data idle periods to avoid waking up CPU unnecessary. The timer will
      still trigger during idle periods, that needs to be fixed later.
      
      There's also a functional change that probe requests are sent only when the
      data path is idle, earlier they were sent also while there was activity
      on the data path.
      
      This is also preparation for the beacon filtering support. Thanks to
      Johannes Berg for the idea.
      Signed-off-by: default avatarKalle Valo <kalle.valo@nokia.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      3cf335d5
    • Johannes Berg's avatar
      mac80211: remove mixed-cell and userspace MLME code · 7986cf95
      Johannes Berg authored
      
      
      Neither can currently be set from userspace, so there's no
      regression potential, and neither will be supported from
      userspace since the new userspace APIs allow the SME, which
      is in userspace, to control all we need.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      7986cf95
    • Jouni Malinen's avatar
      nl80211: Remove NL80211_CMD_SET_MGMT_EXTRA_IE · 65fc73ac
      Jouni Malinen authored
      
      
      The functionality that NL80211_CMD_SET_MGMT_EXTRA_IE provided can now
      be achieved with cleaner design by adding IE(s) into
      NL80211_CMD_TRIGGER_SCAN, NL80211_CMD_AUTHENTICATE,
      NL80211_CMD_ASSOCIATE, NL80211_CMD_DEAUTHENTICATE, and
      NL80211_CMD_DISASSOCIATE.
      
      Since this is a very recently added command and there are no known (or
      known planned) applications using NL80211_CMD_SET_MGMT_EXTRA_IE and
      taken into account how much extra complexity it adds to the IE
      processing we have now (and need to add in the future to fix IE order
      in couple of frames), it looks like the best option is to just remove
      the implementation of this command for now. The enum values themselves
      are left to avoid changing the nl80211 command or attribute numbers.
      Signed-off-by: default avatarJouni Malinen <jouni.malinen@atheros.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      65fc73ac
    • Johannes Berg's avatar
      mac80211: resume properly, add suspend/resume test · 827b1fb4
      Johannes Berg authored
      
      
      When mac80211 resumes, it currently doesn't reconfigure the interfaces
      entirely and also doesn't reconfigure BSS information -- fix this.
      
      Also, to be able to test this, add a debugfs file that just calls
      the suspend/resume code to see what happens when we go through that,
      without needing the time-consuming suspend/resume cycle.
      
      (Original version broke the build for CONFIG_PM=n.  Define alternative
      functions for that situation. -- JWL)
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      827b1fb4
    • Jouni Malinen's avatar
      nl80211: Add MLME primitives to support external SME · 636a5d36
      Jouni Malinen authored
      
      
      This patch adds new nl80211 commands to allow user space to request
      authentication and association (and also deauthentication and
      disassociation). The commands are structured to allow separate
      authentication and association steps, i.e., the interface between
      kernel and user space is similar to the MLME SAP interface in IEEE
      802.11 standard and an user space application takes the role of the
      SME.
      
      The patch introduces MLME-AUTHENTICATE.request,
      MLME-{,RE}ASSOCIATE.request, MLME-DEAUTHENTICATE.request, and
      MLME-DISASSOCIATE.request primitives. The authentication and
      association commands request the actual operations in two steps
      (assuming the driver supports this; if not, separate authentication
      step is skipped; this could end up being a separate "connect"
      command).
      
      The initial implementation for mac80211 uses the current
      net/mac80211/mlme.c for actual sending and processing of management
      frames and the new nl80211 commands will just stop the current state
      machine from moving automatically from authentication to association.
      Future cleanup may move more of the MLME operations into cfg80211.
      
      The goal of this design is to provide more control of authentication and
      association process to user space without having to move the full MLME
      implementation. This should be enough to allow IEEE 802.11r FT protocol
      and 802.11s SAE authentication to be implemented. Obviously, this will
      also bring the extra benefit of not having to use WEXT for association
      requests with mac80211. An example implementation of a user space SME
      using the new nl80211 commands is available for wpa_supplicant.
      
      This patch is enough to get IEEE 802.11r FT protocol working with
      over-the-air mechanism (over-the-DS will need additional MLME
      primitives for handling the FT Action frames).
      Signed-off-by: default avatarJouni Malinen <j@w1.fi>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      636a5d36
    • Johannes Berg's avatar
      mac80211: stop queues across suspend/resume · 25420604
      Johannes Berg authored
      
      
      Even though userland probably cannot submit packets, there might
      still be some coming, and that's no good when the driver doesn't
      expect them. Stop the queues across suspend/resume.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      25420604
  6. 16 Mar, 2009 1 commit
    • Helmut Schaa's avatar
      mac80211: handle failed scan requests in STA mode · af88b907
      Helmut Schaa authored
      
      
      If cfg80211 requests a scan it awaits either a return code != 0 from
      the scan function or the cfg80211_scan_done to be called. In case of
      a STA mac80211's scan function ever returns 0 and queues the scan request.
      If ieee80211_sta_work is executed and ieee80211_start_scan fails for
      some reason cfg80211_scan_done will never be called but cfg80211 still
      thinks the scan was triggered successfully and will refuse any future
      scan requests due to drv->scan_req not being cleaned up.
      
      If a scan is triggered from within the MLME a similar problem appears. If
      ieee80211_start_scan returns an error, local->scan_req will not be reset
      and mac80211 will refuse any future scan requests.
      
      Hence, in both cases call ieee80211_scan_failed (which notifies cfg80211
      and resets local->scan_req) if ieee80211_start_scan returns an error.
      Signed-off-by: default avatarHelmut Schaa <helmut.schaa@googlemail.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      af88b907
  7. 27 Feb, 2009 4 commits
    • Alina Friedrichsen's avatar
      mac80211: Introduce a generic commit() to apply changes · 79f6440c
      Alina Friedrichsen authored
      
      
      This patch introduces a generic commit() function which initiate a
      new network joining process. It should be called after some interface
      config changes, so that the changes get applied more cleanly. Currently
      set_ssid() and set_bssid() call it. Others can be added in future
      patches.
      
      In version 1 the header files was forgotten, sorry.
      Signed-off-by: default avatarAlina Friedrichsen <x-alina@gmx.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      79f6440c
    • Jouni Malinen's avatar
      nl80211: Optional IEs into scan request · 70692ad2
      Jouni Malinen authored
      
      
      This extends the NL80211_CMD_TRIGGER_SCAN command to allow applications
      to specify a set of information element(s) to be added into Probe
      Request frames with NL80211_ATTR_IE. This provides support for the
      MLME-SCAN.request primitive parameter VendorSpecificInfo and can be
      used, e.g., to implement WPS scanning.
      Signed-off-by: default avatarJouni Malinen <jouni.malinen@atheros.com>
      Acked-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      70692ad2
    • Johannes Berg's avatar
      mac80211: split IBSS/managed code · 46900298
      Johannes Berg authored
      
      
      This patch splits out the ibss code and data from managed (station) mode.
      The reason to do this is to better separate the state machines, and have
      the code be contained better so it gets easier to determine what exactly
      a given change will affect, that in turn makes it easier to understand.
      
      This is quite some churn, especially because I split sdata->u.sta into
      sdata->u.mgd and sdata->u.ibss, but I think it's easier to maintain that
      way. I've also shuffled around some code -- null function sending is only
      applicable to managed interfaces so put that into that file, some other
      functions are needed from various places so put them into util, and also
      rearranged the prototypes in ieee80211_i.h accordingly.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      46900298
    • Johannes Berg's avatar
      mac80211: fix aggregation for hardware with ampdu queues · 96f5e66e
      Johannes Berg authored
      
      
      Hardware with AMPDU queues currently has broken aggregation.
      
      This patch fixes it by making all A-MPDUs go over the regular AC queues,
      but keeping track of the hardware queues in mac80211. As a first rough
      version, it actually stops the AC queue for extended periods of time,
      which can be removed by adding buffering internal to mac80211, but is
      currently not a huge problem because people rarely use multiple TIDs
      that are in the same AC (and iwlwifi currently doesn't operate as AP).
      
      This is a short-term fix, my current medium-term plan, which I hope to
      execute soon as well, but am not sure can finish before .30, looks like
      this:
       1) rework the internal queuing layer in mac80211 that we use for
          fragments if the driver stopped queue in the middle of a fragmented
          frame to be able to queue more frames at once (rather than just a
          single frame with its fragments)
       2) instead of stopping the entire AC queue, queue up the frames in a
          per-station/per-TID queue during aggregation session initiation,
          when the session has come up take all those frames and put them
          onto the queue from 1)
       3) push the ampdu queue layer abstraction this patch introduces in
          mac80211 into the driver, and remove the virtual queue stuff from
          mac80211 again
      
      This plan will probably also affect ath9k in that mac80211 queues the
      frames instead of passing them down, even when there are no ampdu queues.
      Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      96f5e66e
  8. 13 Feb, 2009 6 commits