linux-next: manual merge of the wireless-next tree with the nettree
From: Stephen Rothwell
Date: Mon Jun 03 2013 - 22:44:25 EST
Hi John,
Today's linux-next merge of the wireless-next tree got a conflict in
net/mac80211/iface.c between commit ac20976dcaee ("mac80211: Allow single
vif mac address change with addr_mask") from the net tree and commit
31eba5bc56a9 ("mac80211: support active monitor interfaces") from the
wireless-next tree.
I fixed it up (I think - see below) and can carry the fix as necessary
(no action is required).
--
Cheers,
Stephen Rothwell sfr@xxxxxxxxxxxxxxxx
diff --cc net/mac80211/iface.c
index 7c3ba86,7cabaf2..0000000
--- a/net/mac80211/iface.c
+++ b/net/mac80211/iface.c
@@@ -159,10 -159,10 +159,11 @@@ static int ieee80211_change_mtu(struct
return 0;
}
- static int ieee80211_verify_mac(struct ieee80211_sub_if_data *sdata, u8 *addr)
-static int ieee80211_verify_mac(struct ieee80211_local *local, u8 *addr,
++static int ieee80211_verify_mac(struct ieee80211_sub_if_data *sdata, u8 *addr,
+ bool check_dup)
{
- struct ieee80211_sub_if_data *sdata;
+ struct ieee80211_local *local = sdata->local;
+ struct ieee80211_sub_if_data *iter;
u64 new, mask, tmp;
u8 *m;
int ret = 0;
@@@ -180,16 -180,16 +181,19 @@@
((u64)m[2] << 3*8) | ((u64)m[3] << 2*8) |
((u64)m[4] << 1*8) | ((u64)m[5] << 0*8);
+ if (!check_dup)
+ return ret;
mutex_lock(&local->iflist_mtx);
- list_for_each_entry(sdata, &local->interfaces, list) {
- if (sdata->vif.type == NL80211_IFTYPE_MONITOR &&
- !(sdata->u.mntr_flags & MONITOR_FLAG_ACTIVE))
+ list_for_each_entry(iter, &local->interfaces, list) {
+ if (iter == sdata)
continue;
- if (iter->vif.type == NL80211_IFTYPE_MONITOR)
- m = sdata->vif.addr;
++ if (iter->vif.type == NL80211_IFTYPE_MONITOR &&
++ !(iter->u.mntr_flags & MONITOR_FLAG_ACTIVE))
+ continue;
+
+ m = iter->vif.addr;
tmp = ((u64)m[0] << 5*8) | ((u64)m[1] << 4*8) |
((u64)m[2] << 3*8) | ((u64)m[3] << 2*8) |
((u64)m[4] << 1*8) | ((u64)m[5] << 0*8);
@@@ -213,7 -214,11 +218,11 @@@ static int ieee80211_change_mac(struct
if (ieee80211_sdata_running(sdata))
return -EBUSY;
- ret = ieee80211_verify_mac(sdata, sa->sa_data);
+ if (sdata->vif.type == NL80211_IFTYPE_MONITOR &&
+ !(sdata->u.mntr_flags & MONITOR_FLAG_ACTIVE))
+ check_dup = false;
+
- ret = ieee80211_verify_mac(sdata->local, sa->sa_data, check_dup);
++ ret = ieee80211_verify_mac(sdata, sa->sa_data, check_dup);
if (ret)
return ret;
Attachment:
pgp00000.pgp
Description: PGP signature