Skip to content

Commit

Permalink
[PATCH] mac80211: fix set_channel regression
Browse files Browse the repository at this point in the history
Adam Baker reported that the prism2 ioctl removal changed behaviour
in that now the selection order was the other way around as before.
New API is planned but not done yet, so for now just use the first
matching channel in any mode as was previous behaviour with an unset
next_mode.

Signed-off-by: Johannes Berg <[email protected]>
Acked-by: Michael Wu <[email protected]>
Signed-off-by: John W. Linville <[email protected]>
  • Loading branch information
jmberg authored and linvjw committed Oct 17, 2007
1 parent e797aa1 commit 58a9ac1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion net/mac80211/ieee80211_ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -306,9 +306,12 @@ int ieee80211_set_channel(struct ieee80211_local *local, int channel, int freq)
((chan->chan == channel) || (chan->freq == freq))) {
local->oper_channel = chan;
local->oper_hw_mode = mode;
set++;
set = 1;
break;
}
}
if (set)
break;
}

if (set) {
Expand Down

0 comments on commit 58a9ac1

Please sign in to comment.