1. 30 Mar, 2015 16 commits
  2. 20 Mar, 2015 6 commits
    • Johannes Berg's avatar
      cfg80211: add vlan to station add/change tracing · 5d8325ec
      Johannes Berg authored
      This helps debug issues with VLAN modifications that are otherwise
      not really visible in any tracing/debugging.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      5d8325ec
    • Johannes Berg's avatar
      mac80211: avoid duplicate TX path station lookup · 7c10770f
      Johannes Berg authored
      Instead of looking up the destination station twice in the TX path
      (first to build the header, and then for control processing), save
      it when building the header and use it later in the TX path.
      
      To avoid having to look up the station in the many callers, allow
      those to pass %NULL which keeps the existing lookup.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      7c10770f
    • Johannes Berg's avatar
      mac80211: mesh: avoid pointless station lookup · e33f5569
      Johannes Berg authored
      In ieee80211_build_hdr(), the station is looked up to build the
      header correctly (QoS field) and to check for authorization. For
      mesh, authorization isn't checked here, and QoS capability is
      mandatory, so the station lookup can be avoided.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      e33f5569
    • Johannes Berg's avatar
      mac80211: drop 4-addr VLAN frames earlier if not connected · a8d15ff0
      Johannes Berg authored
      If there's no station on the 4-addr VLAN interface, then frames
      cannot be transmitted. Drop such frames earlier, before setting
      up all the information for them.
      
      We should keep the old check though since that code might be used
      for other internally-generated frames.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      a8d15ff0
    • Johannes Berg's avatar
      mac80211: don't look up destination station twice · 5041006c
      Johannes Berg authored
      There's no need to look up the destination station twice while
      building the 802.11 header for a given frame if the frame will
      actually be transmitted to the station we initially looked up.
      
      This happens for 4-addr VLAN interfaces and TDLS connections, which
      both directly send the frame to the station they looked up, though
      in the case of TDLS some station conditions need to be checked.
      
      To avoid that, add a variable indicating that we've looked up the
      station that the frame is going to be transmitted to, and avoid the
      lookup/flag checking if it already has been done.
      
      In the TDLS case, also move the authorized/wme_sta flag assignment
      to the correct place, i.e. only when that station is really used.
      Before this change, the new lookup should always have succeeded so
      that the potentially erroneous data would be overwritten.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      5041006c
    • Johannes Berg's avatar
      mac80211: remove drop_unencrypted code · e8f4fb7c
      Johannes Berg authored
      This mechanism was historic, and only ever used by IBSS, which
      also doesn't need to have it as it properly manages station's
      802.1X PAE state (or, with WEP, always has a key.)
      
      Remove the mechanism to clean up the code.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      e8f4fb7c
  3. 17 Mar, 2015 5 commits
  4. 16 Mar, 2015 4 commits
  5. 06 Mar, 2015 3 commits
    • Ilan peer's avatar
      cfg80211: Schedule timeout for all CRDA calls · eeca9fce
      Ilan peer authored
      Timeout was scheduled only in case CRDA was called due to user hints,
      but was not scheduled for other cases. This can result in regulatory
      hint processing getting stuck in case that there is no CRDA configured.
      
      Change this by scheduling a timeout every time CRDA is called. In
      addition, in restore_regulatory_settings() all pending requests are
      restored (and not only the user ones).
      Signed-off-by: default avatarIlan Peer <ilan.peer@intel.com>
      Acked-by: default avatarLuis R. Rodriguez <mcgrof@suse.com>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      eeca9fce
    • Ilan peer's avatar
      cfg80211: Add API to change the indoor regulatory setting · 05050753
      Ilan peer authored
      Previously, the indoor setting configuration assumed that as
      long as a station interface is connected, the indoor environment
      setting does not change. However, this assumption is problematic
      as:
      
      - It is possible that a station interface is connected to a mobile
        AP, e.g., softAP or a P2P GO, where it is possible that both the
        station and the mobile AP move out of the indoor environment making
        the indoor setting invalid. In such a case, user space has no way to
        invalidate the setting.
      - A station interface disconnection does not necessarily imply that
        the device is no longer operating in an indoor environment, e.g.,
        it is possible that the station interface is roaming but is still
        stays indoor.
      
      To handle the above, extend the indoor configuration API to allow
      user space to indicate a change of indoor settings, and allow it to
      indicate weather it controls the indoor setting, such that:
      
      1. If the user space process explicitly indicates that it is going
         to control the indoor setting, do not clear the indoor setting
         internally, unless the socket is released. The user space process
         should use the NL80211_ATTR_SOCKET_OWNER attribute in the command
         to state that it is going to control the indoor setting.
      2. Reset the indoor setting when restoring the regulatory settings in
         case it is not owned by a user space process.
      
      Based on the above, a user space tool that continuously monitors the
      indoor settings, i.e., tracking power setting, location etc., can
      indicate environment changes to the regulatory core.
      
      It should be noted that currently user space is the only provided mechanism
      used to hint to the regulatory core over the indoor/outdoor environment --
      while the country IEs do have an environment setting this has been completely
      ignored by the regulatory core by design for a while now since country IEs
      typically can contain bogus data.
      Acked-by: default avatarLuis R. Rodriguez <mcgrof@suse.com>
      Signed-off-by: default avatarArikX Nemtsov <arik@wizery.com>
      Signed-off-by: default avatarIlan Peer <ilan.peer@intel.com>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      05050753
    • Ilan peer's avatar
      cfg80211: Simplify the handling of regulatory indoor setting · 0c4ddcd2
      Ilan peer authored
      Directly update the indoor setting without wrapping it as
      a regulatory request, to simplify the processing.
      Acked-by: default avatarLuis R. Rodriguez <mcgrof@suse.com>
      Signed-off-by: default avatarIlan Peer <ilan.peer@intel.com>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      0c4ddcd2
  6. 04 Mar, 2015 6 commits
    • Johannes Berg's avatar
      mac80211_hwsim: fix beacon timers · 56067628
      Johannes Berg authored
      Jouni reported that certain combinations of hwsim test cases failed,
      and we found that beaconing was erroneously enabled too early on any
      channel switch, which lead to the BI of 2000 TU from the first test
      case to leak into the second one, which then didn't beacon properly.
      
      To fix this, set data->beacon_int to zero when all stop beaconing so
      that beaconing cannot be started (which was intended as 'restarted')
      elsewhere.
      
      Additionally, Jouni found that due to this 'restart' and the beacon
      interval handling station interfaces would also have a needlessly
      running beacon timer all the time, of course not doing anything.
      
      To also fix the latter case only use the beacon interval when it's
      actually needed, i.e. when beaconing gets enabled.
      Reported-by: default avatarJouni Malinen <j@w1.fi>
      Tested-by: default avatarJouni Malinen <j@w1.fi>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      56067628
    • Nicholas Mc Guire's avatar
      mesh_plink: fixup type of timeout to match usage · 0df2f6c1
      Nicholas Mc Guire authored
      timeout was being passed as int but assigned from u32/u16 values and used
      as unsigned type. This is really only for better readability.
      Signed-off-by: default avatarNicholas Mc Guire <hofrat@osadl.org>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      0df2f6c1
    • Nicholas Mc Guire's avatar
      mesh_plink: use msecs_to_jiffies for proper time conversion · cc57ac53
      Nicholas Mc Guire authored
      This is primarily an API consolidation and should make things more readable
      it replaces var * HZ / 1000 by msecs_to_jiffies(var) which also handles
      corner cases correctly.
      
      There is a change of behavior as e.g. for HZ 100, t * HZ / 1000 will
      return 0 for t < 10 but msecs_to_jiffies will return at least 1 always.
      Signed-off-by: default avatarNicholas Mc Guire <hofrat@osadl.org>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      cc57ac53
    • SenthilKumar Jegadeesan's avatar
      mac80211: provide station PMF configuration to driver · 64a8cef4
      SenthilKumar Jegadeesan authored
      Some device drivers offload part of aggregation including AddBA/DelBA
      negotiations to firmware. In such scenario, the PMF configuration of
      the station needs to be provided to driver to enable encryption of
      AddBA/DelBA action frames.
      Signed-off-by: default avatarSenthilKumar Jegadeesan <sjegadee@qti.qualcomm.com>
      [fix commit log, documentation]
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      64a8cef4
    • Arik Nemtsov's avatar
      mac80211: allow iterating inactive interfaces · 3384d757
      Arik Nemtsov authored
      Sometimes the driver might want to modify private data in interfaces
      that are down. One possible use-case is cleaning up interface state
      after HW recovery. Some interfaces that were up before the recovery took
      place might be down now, but they might still be "dirty".
      
      Introduce a new iterate_interfaces() API and a new ACTIVE iterator flag.
      This way the internal implementation of the both active and inactive
      APIs remains the same.
      Signed-off-by: default avatarArik Nemtsov <arikx.nemtsov@intel.com>
      Signed-off-by: default avatarEmmanuel Grumbach <emmanuel.grumbach@intel.com>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      3384d757
    • Johannes Berg's avatar
      nl80211: prohibit mixing 'any' and regular wowlan triggers · 98fc4386
      Johannes Berg authored
      If the device supports waking up on 'any' signal - i.e. it continues
      operating as usual and wakes up the host on pretty much anything that
      happens, then it makes no sense to also configure the more restricted
      WoWLAN mode where the device operates more autonomously but also in a
      more restricted fashion.
      
      Currently only cw2100 supports both 'any' and other triggers, but it
      seems to be broken as it doesn't configure anything to the device, so
      we can't currently get into a situation where both even can correctly
      be configured. This is about to change (Intel devices are going to
      support both and have different behaviour depending on configuration)
      so make sure the conflicting modes cannot be configured.
      
      (It seems that cw2100 advertises 'any' and 'disconnect' as a means of
      saying that's what it will always do, but that isn't really the way
      this API was meant to be used nor does it actually mean anything as
      'any' always implies 'disconnect' already, and the driver doesn't
      change device configuration in any way depending on the settings.)
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      98fc4386