linux/net/mac80211
Johannes Berg f444de05d2 cfg80211/mac80211: better channel handling
Currently (all tested with hwsim) you can do stupid
things like setting up an AP on a certain channel,
then adding another virtual interface and making
that associate on another channel -- this will make
the beaconing to move channel but obviously without
the necessary IEs data update.

In order to improve this situation, first make the
configuration APIs (cfg80211 and nl80211) aware of
multi-channel operation -- we'll eventually need
that in the future anyway. There's one userland API
change and one API addition. The API change is that
now SET_WIPHY must be called with virtual interface
index rather than only wiphy index in order to take
effect for that interface -- luckily all current
users (hostapd) do that. For monitor interfaces, the
old setting is preserved, but monitors are always
slaved to other devices anyway so no guarantees.

The second userland API change is the introduction
of a per virtual interface SET_CHANNEL command, that
hostapd should use going forward to make it easier
to understand what's going on (it can automatically
detect a kernel with this command).

Other than mac80211, no existing cfg80211 drivers
are affected by this change because they only allow
a single virtual interface.

mac80211, however, now needs to be aware that the
channel settings are per interface now, and needs
to disallow (for now) real multi-channel operation,
which is another important part of this patch.

One of the immediate benefits is that you can now
start hostapd to operate on a hardware that already
has a connection on another virtual interface, as
long as you specify the same channel.

Note that two things are left unhandled (this is an
improvement -- not a complete fix):

 * different HT/no-HT modes

   currently you could start an HT AP and then
   connect to a non-HT network on the same channel
   which would configure the hardware for no HT;
   that can be fixed fairly easily

 * CSA

   An AP we're connected to on a virtual interface
   might indicate switching channels, and in that
   case we would follow it, regardless of how many
   other interfaces are operating; this requires
   more effort to fix but is pretty rare after all

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-05-07 14:55:50 -04:00
..
aes_ccm.c mac80211: aes_ccm.c remove crypto wrapper and extra args 2008-07-08 14:16:02 -04:00
aes_ccm.h mac80211: pass scratch buffer directly, remove additional pointers 2008-07-08 14:16:02 -04:00
aes_cmac.c mac80211: 802.11w - Add BIP (AES-128-CMAC) 2009-01-29 16:00:02 -05:00
aes_cmac.h mac80211: 802.11w - Add BIP (AES-128-CMAC) 2009-01-29 16:00:02 -05:00
agg-rx.c mac80211: fix stopping RX BA session from timer 2010-04-19 16:41:42 -04:00
agg-tx.c Merge branch 'wireless-2.6' into wireless-next-2.6 2010-04-30 15:13:00 -07:00
cfg.c cfg80211/mac80211: better channel handling 2010-05-07 14:55:50 -04:00
cfg.h [MAC80211]: rename ieee80211_cfg.h to cfg.h 2007-10-10 16:52:34 -07:00
chan.c cfg80211/mac80211: better channel handling 2010-05-07 14:55:50 -04:00
debugfs_key.c mac80211: reduce reliance on netdev 2009-12-21 18:38:52 -05:00
debugfs_key.h mac80211: 802.11w - Use BIP (AES-128-CMAC) 2009-01-29 16:00:03 -05:00
debugfs_netdev.c Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 into merge 2010-04-08 13:34:54 -04:00
debugfs_netdev.h mac80211: reduce reliance on netdev 2009-12-21 18:38:52 -05:00
debugfs_sta.c mac80211: allow controlling aggregation manually 2010-05-03 14:53:10 -04:00
debugfs_sta.h mac80211: RCU-ify STA info structure access 2008-03-06 15:30:46 -05:00
debugfs.c mac80211: Added a new debugfs file for reading channel_type 2010-02-08 16:50:57 -05:00
debugfs.h cfg80211/mac80211: use debugfs_remove_recursive 2009-10-30 16:49:18 -04:00
driver-ops.h mac80211: give virtual interface to hw_scan 2010-04-27 16:09:23 -04:00
driver-trace.c mac80211: fix sparse warnings/errors 2009-08-04 16:43:25 -04:00
driver-trace.h mac80211: give virtual interface to hw_scan 2010-04-27 16:09:23 -04:00
event.c cfg80211: use proper allocation flags 2009-07-10 15:01:49 -04:00
ht.c mac80211: remove ieee80211_sta_stop_rx_ba_session 2010-04-07 14:38:03 -04:00
ibss.c mac80211: use fixed channel in ibss join when appropriate 2010-05-05 15:10:57 -04:00
ieee80211_i.h cfg80211/mac80211: better channel handling 2010-05-07 14:55:50 -04:00
iface.c mac80211: Add support for connection monitor in hardware 2010-03-23 16:51:42 -04:00
Kconfig mac80211: enhance tracing 2010-04-08 15:24:13 -04:00
key.c ath9k: Group Key fix for VAPs 2010-04-20 11:50:51 -04:00
key.h mac80211 : fix a race with update_tkip_key 2009-12-22 13:31:14 -05:00
led.c mac80211: rename files 2008-04-08 16:44:45 -04:00
led.h mac80211: rename files 2008-04-08 16:44:45 -04:00
main.c mac80211: improve IBSS scanning 2010-05-03 14:53:10 -04:00
Makefile cfg80211/mac80211: better channel handling 2010-05-07 14:55:50 -04:00
mesh_hwmp.c mac80211: Moved mesh action codes to a more visible location 2010-04-08 15:24:07 -04:00
mesh_pathtbl.c Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 2009-12-25 16:34:56 -08:00
mesh_plink.c mac80211: Moved mesh action codes to a more visible location 2010-04-08 15:24:07 -04:00
mesh.c mac80211: Moved mesh action codes to a more visible location 2010-04-08 15:24:07 -04:00
mesh.h mac80211: Moved mesh action codes to a more visible location 2010-04-08 15:24:07 -04:00
michael.c mac80211: remove ieee80211_get_hdr_info 2008-07-08 14:16:01 -04:00
michael.h mac80211: remove ieee80211_get_hdr_info 2008-07-08 14:16:01 -04:00
mlme.c Merge branch 'wireless-2.6' into wireless-next-2.6 2010-04-30 15:13:00 -07:00
offchannel.c mac80211: Fixed netif_tx_wake_all_queues in IBSS mode 2010-01-15 16:58:28 -05:00
pm.c mac80211: rename WLAN_STA_SUSPEND to WLAN_STA_BLOCK_BA 2010-04-07 14:38:04 -04:00
rate.c Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 2010-02-26 16:54:45 -05:00
rate.h mac80211: Fix HT rate control configuration 2010-03-03 15:39:21 -05:00
rc80211_minstrel_debugfs.c minstrel: make the rate control ops reusable from another rc implementation 2010-03-10 17:44:23 -05:00
rc80211_minstrel.c minstrel: make the rate control ops reusable from another rc implementation 2010-03-10 17:44:23 -05:00
rc80211_minstrel.h minstrel: make the rate control ops reusable from another rc implementation 2010-03-10 17:44:23 -05:00
rc80211_pid_algo.c mac80211: pid: replace open-coded msecs_to_jiffies 2010-01-19 16:25:15 -05:00
rc80211_pid_debugfs.c headers: remove sched.h from interrupt.h 2009-10-11 11:20:58 -07:00
rc80211_pid.h mac80211/drivers: rewrite the rate control API 2008-10-31 19:00:23 -04:00
rx.c mac80211: remove deprecated noise field from ieee80211_rx_status 2010-04-30 15:38:13 -04:00
scan.c mac80211: improve IBSS scanning 2010-05-03 14:53:10 -04:00
spectmgmt.c mac80211: reduce reliance on netdev 2009-12-21 18:38:52 -05:00
sta_info.c mac80211: fix ieee80211_find_sta[_by_hw] 2010-05-03 14:51:47 -04:00
sta_info.h mac80211: clean up/fix aggregation code 2010-04-07 14:38:05 -04:00
status.c mac80211: Fix sta->last_tx_rate setting with no-op rate control devices 2010-04-26 14:11:40 -04:00
tkip.c mac80211: pass vif and station to update_tkip_key 2010-01-22 16:08:55 -05:00
tkip.h mac80211: tkip.c consolidate tkip IV writing in helper 2008-06-14 12:18:13 -04:00
tx.c mac80211: fix rts threshold check 2010-04-27 16:09:23 -04:00
util.c mac80211: fix BSS info reconfiguration 2010-05-07 14:55:49 -04:00
wep.c mac80211: avoid NULL ptr deref when using WEP 2010-01-22 12:39:14 -05:00
wep.h cfg80211: rework key operation 2009-07-24 15:05:09 -04:00
wme.c mac80211: fix-up build breakage in 2.6.33 2010-01-06 15:35:49 -05:00
wme.h mac80211: fix skb buffering issue 2010-01-05 16:21:40 -05:00
work.c mac80211: fix supported rates IE if AP doesn't give us it's rates 2010-04-28 16:50:29 -04:00
wpa.c mac80211: move control.hw_key assignment 2010-01-19 16:25:19 -05:00
wpa.h mac80211: 802.11w - Add BIP (AES-128-CMAC) 2009-01-29 16:00:02 -05:00