2009/1/22 Bob Copeland <me@xxxxxxxxxxxxxxx>: > ath5k_config updates the software context without taking sc->lock. > > Changes-licensed-under: 3-Clause-BSD > > Signed-off-by: Bob Copeland <me@xxxxxxxxxxxxxxx> > --- > drivers/net/wireless/ath5k/base.c | 10 +++++++++- > 1 files changed, 9 insertions(+), 1 deletions(-) > > diff --git a/drivers/net/wireless/ath5k/base.c b/drivers/net/wireless/ath5k/base.c > index 747b496..1e1222c 100644 > --- a/drivers/net/wireless/ath5k/base.c > +++ b/drivers/net/wireless/ath5k/base.c > @@ -1021,6 +1021,8 @@ ath5k_setup_bands(struct ieee80211_hw *hw) > * it's done by reseting the chip. To accomplish this we must > * first cleanup any pending DMA, then restart stuff after a la > * ath5k_init. > + * > + * Called with sc->lock. > */ > static int > ath5k_chan_set(struct ath5k_softc *sc, struct ieee80211_channel *chan) > @@ -2825,11 +2827,17 @@ ath5k_config(struct ieee80211_hw *hw, u32 changed) > { > struct ath5k_softc *sc = hw->priv; > struct ieee80211_conf *conf = &hw->conf; > + int ret; > + > + mutex_lock(&sc->lock); > > sc->bintval = conf->beacon_int; > sc->power_level = conf->power_level; > > - return ath5k_chan_set(sc, conf->channel); > + ret = ath5k_chan_set(sc, conf->channel); > + > + mutex_unlock(&sc->lock); > + return ret; > } > > static int Acked-by: Nick Kossifidis <mickflemm@xxxxxxxxx> -- GPG ID: 0xD21DB2DB As you read this post global entropy rises. Have Fun ;-) Nick -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html