Skip to content

Commit

Permalink
wl12xx: initialize rate_set on band rates initialization
Browse files Browse the repository at this point in the history
In some corner cases, (invalid) 11g rates were used while
working on 11a band.

Take care of it by initializing rate_set according to the
configured band.

Signed-off-by: Eliad Peller <eliad@wizery.com>
Signed-off-by: Luciano Coelho <coelho@ti.com>
  • Loading branch information
Eliad Peller authored and Luciano Coelho committed Aug 25, 2011
1 parent cabb81c commit 53835a2
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions drivers/net/wireless/wl12xx/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2200,10 +2200,14 @@ static int wl1271_unjoin(struct wl1271 *wl)

static void wl1271_set_band_rate(struct wl1271 *wl)
{
if (wl->band == IEEE80211_BAND_2GHZ)
if (wl->band == IEEE80211_BAND_2GHZ) {
wl->basic_rate_set = wl->conf.tx.basic_rate;
else
wl->rate_set = wl->conf.tx.basic_rate;
} else {
wl->basic_rate_set = wl->conf.tx.basic_rate_5;
wl->rate_set = wl->conf.tx.basic_rate_5;
}

}

static bool wl12xx_is_roc(struct wl1271 *wl)
Expand Down

0 comments on commit 53835a2

Please sign in to comment.