diff options
author | Juuso Oikarinen <juuso.oikarinen@nokia.com> | 2009-10-12 08:08:53 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-10-27 16:48:05 -0400 |
commit | 207347e498cbe25fa2a8369edd49df43e56000be (patch) | |
tree | f970b3384de1f2074d126d01930fe4df6b9ba5fb | |
parent | 3cfd6cf960b2b030ccae1144a5c0dcd91c7c56a8 (diff) |
wl1271: Update TX path block calucation algo
Update the TX path block calculation algorithm based on TI reference.
Signed-off-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>
Reviewed-by: Luciano Coelho <luciano.coelho@nokia.com>
Signed-off-by: Luciano Coelho <luciano.coelho@nokia.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/wl12xx/wl1271_tx.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1271_tx.c b/drivers/net/wireless/wl12xx/wl1271_tx.c index 5d3aa4b26cf3..56a7f36380b7 100644 --- a/drivers/net/wireless/wl12xx/wl1271_tx.c +++ b/drivers/net/wireless/wl12xx/wl1271_tx.c | |||
@@ -57,8 +57,8 @@ static int wl1271_tx_allocate(struct wl1271 *wl, struct sk_buff *skb, u32 extra) | |||
57 | /* approximate the number of blocks required for this packet | 57 | /* approximate the number of blocks required for this packet |
58 | in the firmware */ | 58 | in the firmware */ |
59 | /* FIXME: try to figure out what is done here and make it cleaner */ | 59 | /* FIXME: try to figure out what is done here and make it cleaner */ |
60 | total_blocks = (total_len) >> TX_HW_BLOCK_SHIFT_DIV; | 60 | total_blocks = (total_len + 20) >> TX_HW_BLOCK_SHIFT_DIV; |
61 | excluded = (total_blocks << 2) + (skb->len & 0xff) + 34; | 61 | excluded = (total_blocks << 2) + ((total_len + 20) & 0xff) + 34; |
62 | total_blocks += (excluded > 252) ? 2 : 1; | 62 | total_blocks += (excluded > 252) ? 2 : 1; |
63 | total_blocks += TX_HW_BLOCK_SPARE; | 63 | total_blocks += TX_HW_BLOCK_SPARE; |
64 | 64 | ||