diff options
author | Arik Nemtsov <arik@wizery.com> | 2010-10-16 12:19:53 -0400 |
---|---|---|
committer | Luciano Coelho <coelho@ti.com> | 2011-01-24 15:11:48 -0500 |
commit | e0fe371b74326a85029fe8720506e021fe73905a (patch) | |
tree | 0eb9864739ae8c876560598aefb410e7c7bec3e6 /drivers/net/wireless/wl12xx/tx.c | |
parent | 05285cf9b581af05813cfaa60e23227b009b7754 (diff) |
wl12xx: AP mode - init sequence
Split HW init sequence into AP/STA specific parts
The AP specific init sequence includes configuration of templates, rate
classes, power mode, etc. Also unmask AP specific events in the event mbox.
Separate the differences between AP and STA init into mode
specific functions called from wl1271_hw_init. The first is called after
radio configuration and the second after memory configuration.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Reviewed-by: Luciano Coelho <coelho@ti.com>
Signed-off-by: Luciano Coelho <coelho@ti.com>
Diffstat (limited to 'drivers/net/wireless/wl12xx/tx.c')
-rw-r--r-- | drivers/net/wireless/wl12xx/tx.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/drivers/net/wireless/wl12xx/tx.c b/drivers/net/wireless/wl12xx/tx.c index 442a7bd956e..a93fc4702f3 100644 --- a/drivers/net/wireless/wl12xx/tx.c +++ b/drivers/net/wireless/wl12xx/tx.c | |||
@@ -521,3 +521,21 @@ void wl1271_tx_flush(struct wl1271 *wl) | |||
521 | 521 | ||
522 | wl1271_warning("Unable to flush all TX buffers, timed out."); | 522 | wl1271_warning("Unable to flush all TX buffers, timed out."); |
523 | } | 523 | } |
524 | |||
525 | u32 wl1271_tx_min_rate_get(struct wl1271 *wl) | ||
526 | { | ||
527 | int i; | ||
528 | u32 rate = 0; | ||
529 | |||
530 | if (!wl->basic_rate_set) { | ||
531 | WARN_ON(1); | ||
532 | wl->basic_rate_set = wl->conf.tx.basic_rate; | ||
533 | } | ||
534 | |||
535 | for (i = 0; !rate; i++) { | ||
536 | if ((wl->basic_rate_set >> i) & 0x1) | ||
537 | rate = 1 << i; | ||
538 | } | ||
539 | |||
540 | return rate; | ||
541 | } | ||