[802.11] Set channels early on to avoid tuning to an undefined channel
authorJoshua Oreman <oremanj@rwcr.net>
Sat, 1 Aug 2009 16:52:59 +0000 (09:52 -0700)
committerMichael Brown <mcb30@etherboot.org>
Sat, 8 Aug 2009 23:11:33 +0000 (00:11 +0100)
commit1e810bebe95eafc3c8427d7c5ddf753debb1316e
treed1e00b123b5402cf9d6f1532066a91af4a9d2d17
parentf128a6db21339964c52fb7bcfc6c8a3ffa96387b
[802.11] Set channels early on to avoid tuning to an undefined channel

Some cards (such as ath5k) always need to tune to a particular channel
when they are reset; the reset may happen upon open(), which is before
the channels array would be set up (in prepare_probe()). Avoid tuning
the card to an inconsistent state by copying the hardware
supported-channels array to the 802.11 device's allowable-channels
array even before channels are "properly" set up.

Signed-off-by: Michael Brown <mcb30@etherboot.org>
src/net/80211/net80211.c