Ath5k: fix bintval setup
bintval is set to the initial value at .config_interface which is too late, since it overwrites previously set value from .config. Move the initialization to the .add_interface. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Cc: Nick Kossifidis <mickflemm@gmail.com> Cc: Luis R. Rodriguez <mcgrof@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
committed by
John W. Linville
parent
004829730c
commit
67d2e2dfab
@@ -2751,6 +2751,11 @@ static int ath5k_add_interface(struct ieee80211_hw *hw,
|
|||||||
ret = -EOPNOTSUPP;
|
ret = -EOPNOTSUPP;
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Set to a reasonable value. Note that this will
|
||||||
|
* be set to mac80211's value at ath5k_config(). */
|
||||||
|
sc->bintval = 1000;
|
||||||
|
|
||||||
ret = 0;
|
ret = 0;
|
||||||
end:
|
end:
|
||||||
mutex_unlock(&sc->lock);
|
mutex_unlock(&sc->lock);
|
||||||
@@ -2795,9 +2800,6 @@ ath5k_config_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
|
|||||||
struct ath5k_hw *ah = sc->ah;
|
struct ath5k_hw *ah = sc->ah;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
/* Set to a reasonable value. Note that this will
|
|
||||||
* be set to mac80211's value at ath5k_config(). */
|
|
||||||
sc->bintval = 1000;
|
|
||||||
mutex_lock(&sc->lock);
|
mutex_lock(&sc->lock);
|
||||||
if (sc->vif != vif) {
|
if (sc->vif != vif) {
|
||||||
ret = -EIO;
|
ret = -EIO;
|
||||||
|
Reference in New Issue
Block a user