1. 22 2月, 2012 2 次提交
    • M
      mac80211: Fix a warning on changing to monitor mode from STA · 0dee0068
      Mohammed Shafi Shajakhan 提交于
      nothing needs to be done for monitor/AP_VLAN mode on calling
      ieee80211_bss_info_change_notify -> drv_bss_info_changed with the change
      flag 'BSS_CHANGED_IDLE'. 'wl1271' seems to use BSS_CHANGED_IDLE only for
      STA and IBSS mode. further the non-idle state of the monitor mode is
      taken care by the 'count' variable which counts non-idle interfaces.
      ieee80211_idle_off(local, "in use") will be called.
      this fixes the following WARNING when we have initially STA mode
      (network manager running) and not associated, and change it to monitor
      mode with network manager disabled and bringing up the monitor mode.
      this changes the idle state from 'true' (STA unassociated) to 'false'
      (MONITOR mode)
      exposed by the commit 405385f8
      "mac80211: set bss_conf.idle when vif is connected"
      
      	WARNING: net/mac80211/main.c:212
      	ieee80211_bss_info_change_notify+0x1cf/0x330 [mac80211]()
      	Hardware name: 64756D6
      	Pid: 3835, comm: ifconfig Tainted: G           O
      	3.3.0-rc3-wl #9
      	Call Trace:
      	  [<c0133b02>] warn_slowpath_common+0x72/0xa0
      	  [<fc8e8c3f>] ?
      	  ieee80211_bss_info_change_notify+0x1cf/0x330 [mac80211]
      	  [<fc8e8c3f>] ?
      	  ieee80211_bss_info_change_notify+0x1cf/0x330 [mac80211]
      	  [<c0133b52>] warn_slowpath_null+0x22/0x30
      	  [<fc8e8c3f>]
      	  ieee80211_bss_info_change_notify+0x1cf/0x330 [mac80211]
      	  [<fc8f9de3>] __ieee80211_recalc_idle+0x113/0x430
      	  [mac80211]
      	  [<fc8fabc6>] ieee80211_do_open+0x156/0x7e0 [mac80211]
      	  [<fc8f8a25>] ?
      	  ieee80211_check_concurrent_iface+0x25/0x180 [mac80211]
      	  [<c015dd9f>] ? raw_notifier_call_chain+0x1f/0x30
      	  [<fc8fb290>] ieee80211_open+0x40/0x80 [mac80211]
      	  [<c05894f6>] __dev_open+0x96/0xe0
      	  [<c068fba5>] ? _raw_spin_unlock_bh+0x35/0x40
      	  [<c05881d9>] __dev_change_flags+0x109/0x170
      	  [<c0589423>] dev_change_flags+0x23/0x60
      	  [<c05f3770>] devinet_ioctl+0x6a0/0x770
      
       ieee80211 phy0: device no longer idle - in use
      
      Cc: Eliad Peller <eliad@wizery.com>
      Signed-off-by: NMohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      0dee0068
    • M
      mac80211: zero initialize count field in ieee80211_tx_rate · 8617b093
      Mohammed Shafi Shajakhan 提交于
      rate control algorithms concludes the rate as invalid
      with rate[i].idx < -1 , while they do also check for rate[i].count is
      non-zero. it would be safer to zero initialize the 'count' field.
      recently we had a ath9k rate control crash where the ath9k rate control
      in ath_tx_status assumed to check only for rate[i].count being non-zero
      in one instance and ended up in using invalid rate index for
      'connection monitoring NULL func frames' which eventually lead to the crash.
      thanks to Pavel Roskin for fixing it and finding the root cause.
      https://bugzilla.redhat.com/show_bug.cgi?id=768639
      
      Cc: stable@vger.kernel.org
      Cc: Pavel Roskin <proski@gnu.org>
      Signed-off-by: NMohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      8617b093
  2. 16 2月, 2012 2 次提交
  3. 10 2月, 2012 1 次提交
    • M
      mac80211: Fix a rwlock bad magic bug · b57e6b56
      Mohammed Shafi Shajakhan 提交于
      read_lock(&tpt_trig->trig.leddev_list_lock) is accessed via the path
      ieee80211_open (->) ieee80211_do_open (->) ieee80211_mod_tpt_led_trig
      (->) ieee80211_start_tpt_led_trig (->) tpt_trig_timer before initializing
      it.
      the intilization of this read/write lock happens via the path
      ieee80211_led_init (->) led_trigger_register, but we are doing
      'ieee80211_led_init'  after 'ieeee80211_if_add' where we
      register netdev_ops.
      so we access leddev_list_lock before initializing it and causes the
      following bug in chrome laptops with AR928X cards with the following
      script
      
      while true
      do
      sudo modprobe -v ath9k
      sleep 3
      sudo modprobe -r ath9k
      sleep 3
      done
      
      	BUG: rwlock bad magic on CPU#1, wpa_supplicant/358, f5b9eccc
      	Pid: 358, comm: wpa_supplicant Not tainted 3.0.13 #1
      	Call Trace:
      
      	[<8137b9df>] rwlock_bug+0x3d/0x47
      	[<81179830>] do_raw_read_lock+0x19/0x29
      	[<8137f063>] _raw_read_lock+0xd/0xf
      	[<f9081957>] tpt_trig_timer+0xc3/0x145 [mac80211]
      	[<f9081f3a>] ieee80211_mod_tpt_led_trig+0x152/0x174 [mac80211]
      	[<f9076a3f>] ieee80211_do_open+0x11e/0x42e [mac80211]
      	[<f9075390>] ? ieee80211_check_concurrent_iface+0x26/0x13c [mac80211]
      	[<f9076d97>] ieee80211_open+0x48/0x4c [mac80211]
      	[<812dbed8>] __dev_open+0x82/0xab
      	[<812dc0c9>] __dev_change_flags+0x9c/0x113
      	[<812dc1ae>] dev_change_flags+0x18/0x44
      	[<8132144f>] devinet_ioctl+0x243/0x51a
      	[<81321ba9>] inet_ioctl+0x93/0xac
      	[<812cc951>] sock_ioctl+0x1c6/0x1ea
      	[<812cc78b>] ? might_fault+0x20/0x20
      	[<810b1ebb>] do_vfs_ioctl+0x46e/0x4a2
      	[<810a6ebb>] ? fget_light+0x2f/0x70
      	[<812ce549>] ? sys_recvmsg+0x3e/0x48
      	[<810b1f35>] sys_ioctl+0x46/0x69
      	[<8137fa77>] sysenter_do_call+0x12/0x2
      
      Cc: <stable@vger.kernel.org>
      Cc: Gary Morain <gmorain@google.com>
      Cc: Paul Stewart <pstew@google.com>
      Cc: Abhijit Pradhan <abhijit@qca.qualcomm.com>
      Cc: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
      Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
      Acked-by: NJohannes Berg <johannes.berg@intel.com>
      Tested-by: NMohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
      Signed-off-by: NMohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      b57e6b56
  4. 02 2月, 2012 1 次提交
  5. 25 1月, 2012 2 次提交
  6. 19 1月, 2012 3 次提交
  7. 17 1月, 2012 3 次提交
  8. 14 1月, 2012 1 次提交
    • J
      mac80211: fix no-op authorized transitions · 543d1b92
      Johannes Berg 提交于
      When userspace attempts to authorize a station
      that is already authorized, nothing happens as
      you'd expect. Similarly, when it unauthorizes
      a station that is associated, nothing happens.
      
      However, when it unauthorizes a station that
      isn't even associated yet, we erroneously try
      to move the station to associated. This seems
      to happen occasionally as a result of a race
      when wpa_supplicant attempts to unauthorize
      the port in managed mode. Particularly with my
      new patches to keep stations, it can then move
      a station into ASSOCIATED state before we have
      really associated, which is really confusing.
      
      I introduced this bug in
      "mac80211: refactor station state transitions"
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      543d1b92
  9. 13 1月, 2012 1 次提交
  10. 12 1月, 2012 1 次提交
  11. 05 1月, 2012 7 次提交
  12. 22 12月, 2011 2 次提交
  13. 20 12月, 2011 5 次提交
  14. 16 12月, 2011 9 次提交