Prev: [patch 034/164] USB: kl5usb105: fix memory leak
Next: [patch 040/164] USB: xhci: Limit bus sg_tablesize to 62 TRBs.
From: Greg KH on 1 Jul 2010 18:20 2.6.33-stable review patch. If anyone has any objections, please let me know. ------------------ From: Felix Fietkau <nbd(a)openwrt.org> commit f7917af92024d43bc20bc1afc92de27b0bd0f50b upstream. A misplaced interface type check bails out too early if the interface is not in monitor mode. This patch moves it to the right place, so that it only covers changes to the monitor flags. Signed-off-by: Felix Fietkau <nbd(a)openwrt.org> Signed-off-by: John W. Linville <linville(a)tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh(a)suse.de> --- net/mac80211/cfg.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c @@ -98,9 +98,6 @@ static int ieee80211_change_iface(struct params->mesh_id_len, params->mesh_id); - if (sdata->vif.type != NL80211_IFTYPE_MONITOR || !flags) - return 0; - if (type == NL80211_IFTYPE_AP_VLAN && params && params->use_4addr == 0) rcu_assign_pointer(sdata->u.vlan.sta, NULL); @@ -108,7 +105,9 @@ static int ieee80211_change_iface(struct params && params->use_4addr >= 0) sdata->u.mgd.use_4addr = params->use_4addr; - sdata->u.mntr_flags = *flags; + if (sdata->vif.type == NL80211_IFTYPE_MONITOR && flags) + sdata->u.mntr_flags = *flags; + return 0; } -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ |