]> Pileus Git - ~andy/linux/commitdiff
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wirel...
authorJohn W. Linville <linville@tuxdriver.com>
Fri, 11 Nov 2011 16:34:47 +0000 (11:34 -0500)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 11 Nov 2011 16:34:47 +0000 (11:34 -0500)
1  2 
net/mac80211/mlme.c
net/mac80211/rx.c
net/mac80211/util.c
net/wireless/reg.c

diff --combined net/mac80211/mlme.c
index 234ffc256a00ec73d821db3ca9c260a99681d659,40db011da580e05f0aaa53ec663949ff57617c85..b1b1bb368f701f61b47da0040ce9b0b477d09deb
  #include <linux/skbuff.h>
  #include <linux/if_arp.h>
  #include <linux/etherdevice.h>
 +#include <linux/moduleparam.h>
  #include <linux/rtnetlink.h>
  #include <linux/pm_qos.h>
  #include <linux/crc32.h>
  #include <linux/slab.h>
 +#include <linux/export.h>
  #include <net/mac80211.h>
  #include <asm/unaligned.h>
  
@@@ -2288,6 -2286,7 +2288,7 @@@ void ieee80211_sta_quiesce(struct ieee8
  
        cancel_work_sync(&ifmgd->request_smps_work);
  
+       cancel_work_sync(&ifmgd->monitor_work);
        cancel_work_sync(&ifmgd->beacon_connection_loss_work);
        if (del_timer_sync(&ifmgd->timer))
                set_bit(TMR_RUNNING_TIMER, &ifmgd->timers_running);
        if (del_timer_sync(&ifmgd->chswitch_timer))
                set_bit(TMR_RUNNING_CHANSW, &ifmgd->timers_running);
  
-       cancel_work_sync(&ifmgd->monitor_work);
        /* these will just be re-established on connection */
        del_timer_sync(&ifmgd->conn_mon_timer);
        del_timer_sync(&ifmgd->bcn_mon_timer);
diff --combined net/mac80211/rx.c
index bb53726cb04a6d1395f7738e87e58845df3716bf,097b42d286e24cc1cc1b98328727853c73de642d..fb123e2e081a4c51495331f4d8cad945e53c3f40
@@@ -16,7 -16,6 +16,7 @@@
  #include <linux/netdevice.h>
  #include <linux/etherdevice.h>
  #include <linux/rcupdate.h>
 +#include <linux/export.h>
  #include <net/mac80211.h>
  #include <net/ieee80211_radiotap.h>
  
@@@ -141,8 -140,9 +141,9 @@@ ieee80211_add_rx_radiotap_header(struc
        pos++;
  
        /* IEEE80211_RADIOTAP_RATE */
-       if (status->flag & RX_FLAG_HT) {
+       if (!rate || status->flag & RX_FLAG_HT) {
                /*
+                * Without rate information don't add it. If we have,
                 * MCS information is a separate field in radiotap,
                 * added below. The byte here is needed as padding
                 * for the channel though, so initialise it to 0.
        else if (status->flag & RX_FLAG_HT)
                put_unaligned_le16(IEEE80211_CHAN_DYN | IEEE80211_CHAN_2GHZ,
                                   pos);
-       else if (rate->flags & IEEE80211_RATE_ERP_G)
+       else if (rate && rate->flags & IEEE80211_RATE_ERP_G)
                put_unaligned_le16(IEEE80211_CHAN_OFDM | IEEE80211_CHAN_2GHZ,
                                   pos);
-       else
+       else if (rate)
                put_unaligned_le16(IEEE80211_CHAN_CCK | IEEE80211_CHAN_2GHZ,
                                   pos);
+       else
+               put_unaligned_le16(IEEE80211_CHAN_2GHZ, pos);
        pos += 2;
  
        /* IEEE80211_RADIOTAP_DBM_ANTSIGNAL */
diff --combined net/mac80211/util.c
index 51e256c5fb78801f8fd570192a78c38367ec9bf2,0c9490722aa53f6d6bb5a19023a2157e9c997828..eca0fad09709518266d9aed37c61f75e2f05afcf
@@@ -13,7 -13,6 +13,7 @@@
  
  #include <net/mac80211.h>
  #include <linux/netdevice.h>
 +#include <linux/export.h>
  #include <linux/types.h>
  #include <linux/slab.h>
  #include <linux/skbuff.h>
@@@ -881,6 -880,8 +881,8 @@@ struct sk_buff *ieee80211_build_probe_r
        skb = ieee80211_probereq_get(&local->hw, &sdata->vif,
                                     ssid, ssid_len,
                                     buf, buf_len);
+       if (!skb)
+               goto out;
  
        if (dst) {
                mgmt = (struct ieee80211_mgmt *) skb->data;
        }
  
        IEEE80211_SKB_CB(skb)->flags |= IEEE80211_TX_INTFL_DONT_ENCRYPT;
+  out:
        kfree(buf);
  
        return skb;
diff --combined net/wireless/reg.c
index 6acba9d18cc873cb97b6c190d526985704371876,bc1ec2c26fd02c1600b8c2c7db44d592916e75c5..e71f5a66574e31cb1d4e44429402ddcb5a61a529
  #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
  
  #include <linux/kernel.h>
 +#include <linux/export.h>
  #include <linux/slab.h>
  #include <linux/list.h>
  #include <linux/random.h>
  #include <linux/ctype.h>
  #include <linux/nl80211.h>
  #include <linux/platform_device.h>
 +#include <linux/moduleparam.h>
  #include <net/cfg80211.h>
  #include "core.h"
  #include "reg.h"
@@@ -2265,6 -2263,9 +2265,9 @@@ void /* __init_or_exit */ regulatory_ex
  
        kfree(last_request);
  
+       last_request = NULL;
+       dev_set_uevent_suppress(&reg_pdev->dev, true);
        platform_device_unregister(reg_pdev);
  
        spin_lock_bh(&reg_pending_beacons_lock);