ath9k: Pause other virtual wiphys on channel change
For now, allow channel changes immediately and just force the other
virtual wiphys to paused state. This is needed to allow
mac80211-controlled scan to control channel changes.
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
diff --git a/drivers/net/wireless/ath9k/main.c b/drivers/net/wireless/ath9k/main.c
index 7c20da3..9b5f214 100644
--- a/drivers/net/wireless/ath9k/main.c
+++ b/drivers/net/wireless/ath9k/main.c
@@ -2343,7 +2343,13 @@
aphy->chan_is_ht = conf_is_ht(conf);
/* TODO: do not change operation channel immediately if there
- * are other virtual wiphys that use another channel */
+ * are other virtual wiphys that use another channel. For now,
+ * we do the change immediately to allow mac80211-operated scan
+ * to work. Once the scan operation is moved into ath9k, we can
+ * just move the current aphy in PAUSED state if the channel is
+ * changed into something different from the current operation
+ * channel. */
+ ath9k_wiphy_pause_all_forced(sc, aphy);
DPRINTF(sc, ATH_DBG_CONFIG, "Set channel: %d MHz\n",
curchan->center_freq);