]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
cfg80211: fix set but not used warning in nl80211_channel_switch()
authorFabian Frederick <fabf@skynet.be>
Sat, 25 Oct 2014 15:57:35 +0000 (17:57 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Wed, 29 Oct 2014 17:42:51 +0000 (18:42 +0100)
radar_detect_width is unused since commit 97dc94f1d933
("cfg80211: remove channel_switch combination check")

Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/wireless/nl80211.c

index 12736a7cd506959be8e6a42040161b8292cbc5d4..33aff7466f2ff36d42f5ce77c80595543b7e426d 100644 (file)
@@ -6038,7 +6038,6 @@ static int nl80211_channel_switch(struct sk_buff *skb, struct genl_info *info)
         * function is called under RTNL lock, so this should not be a problem.
         */
        static struct nlattr *csa_attrs[NL80211_ATTR_MAX+1];
-       u8 radar_detect_width = 0;
        int err;
        bool need_new_beacon = false;
        int len, i;
@@ -6174,10 +6173,8 @@ static int nl80211_channel_switch(struct sk_buff *skb, struct genl_info *info)
        if (err < 0)
                return err;
 
-       if (err > 0) {
-               radar_detect_width = BIT(params.chandef.width);
+       if (err > 0)
                params.radar_required = true;
-       }
 
        if (info->attrs[NL80211_ATTR_CH_SWITCH_BLOCK_TX])
                params.block_tx = true;