3 Broadcom B43 wireless driver
5 Transmission (TX/RX) related functions.
7 Copyright (C) 2005 Martin Langer <martin-langer@gmx.de>
8 Copyright (C) 2005 Stefano Brivio <stefano.brivio@polimi.it>
9 Copyright (C) 2005, 2006 Michael Buesch <mb@bu3sch.de>
10 Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org>
11 Copyright (C) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch>
13 This program is free software; you can redistribute it and/or modify
14 it under the terms of the GNU General Public License as published by
15 the Free Software Foundation; either version 2 of the License, or
16 (at your option) any later version.
18 This program is distributed in the hope that it will be useful,
19 but WITHOUT ANY WARRANTY; without even the implied warranty of
20 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 GNU General Public License for more details.
23 You should have received a copy of the GNU General Public License
24 along with this program; see the file COPYING. If not, write to
25 the Free Software Foundation, Inc., 51 Franklin Steet, Fifth Floor,
26 Boston, MA 02110-1301, USA.
31 #include "phy_common.h"
36 /* Extract the bitrate index out of a CCK PLCP header. */
37 static int b43_plcp_get_bitrate_idx_cck(struct b43_plcp_hdr6 *plcp)
39 switch (plcp->raw[0]) {
52 /* Extract the bitrate index out of an OFDM PLCP header. */
53 static int b43_plcp_get_bitrate_idx_ofdm(struct b43_plcp_hdr6 *plcp, bool aphy)
55 int base = aphy ? 0 : 4;
57 switch (plcp->raw[0] & 0xF) {
78 u8 b43_plcp_get_ratecode_cck(const u8 bitrate)
81 case B43_CCK_RATE_1MB:
83 case B43_CCK_RATE_2MB:
85 case B43_CCK_RATE_5MB:
87 case B43_CCK_RATE_11MB:
94 u8 b43_plcp_get_ratecode_ofdm(const u8 bitrate)
97 case B43_OFDM_RATE_6MB:
99 case B43_OFDM_RATE_9MB:
101 case B43_OFDM_RATE_12MB:
103 case B43_OFDM_RATE_18MB:
105 case B43_OFDM_RATE_24MB:
107 case B43_OFDM_RATE_36MB:
109 case B43_OFDM_RATE_48MB:
111 case B43_OFDM_RATE_54MB:
118 void b43_generate_plcp_hdr(struct b43_plcp_hdr4 *plcp,
119 const u16 octets, const u8 bitrate)
121 __u8 *raw = plcp->raw;
123 if (b43_is_ofdm_rate(bitrate)) {
126 d = b43_plcp_get_ratecode_ofdm(bitrate);
127 B43_WARN_ON(octets & 0xF000);
129 plcp->data = cpu_to_le32(d);
133 plen = octets * 16 / bitrate;
134 if ((octets * 16 % bitrate) > 0) {
136 if ((bitrate == B43_CCK_RATE_11MB)
137 && ((octets * 8 % 11) < 4)) {
143 plcp->data |= cpu_to_le32(plen << 16);
144 raw[0] = b43_plcp_get_ratecode_cck(bitrate);
148 static u8 b43_calc_fallback_rate(u8 bitrate)
151 case B43_CCK_RATE_1MB:
152 return B43_CCK_RATE_1MB;
153 case B43_CCK_RATE_2MB:
154 return B43_CCK_RATE_1MB;
155 case B43_CCK_RATE_5MB:
156 return B43_CCK_RATE_2MB;
157 case B43_CCK_RATE_11MB:
158 return B43_CCK_RATE_5MB;
159 case B43_OFDM_RATE_6MB:
160 return B43_CCK_RATE_5MB;
161 case B43_OFDM_RATE_9MB:
162 return B43_OFDM_RATE_6MB;
163 case B43_OFDM_RATE_12MB:
164 return B43_OFDM_RATE_9MB;
165 case B43_OFDM_RATE_18MB:
166 return B43_OFDM_RATE_12MB;
167 case B43_OFDM_RATE_24MB:
168 return B43_OFDM_RATE_18MB;
169 case B43_OFDM_RATE_36MB:
170 return B43_OFDM_RATE_24MB;
171 case B43_OFDM_RATE_48MB:
172 return B43_OFDM_RATE_36MB;
173 case B43_OFDM_RATE_54MB:
174 return B43_OFDM_RATE_48MB;
180 /* Generate a TX data header. */
181 int b43_generate_txhdr(struct b43_wldev *dev,
183 const unsigned char *fragment_data,
184 unsigned int fragment_len,
185 struct ieee80211_tx_info *info,
188 struct b43_txhdr *txhdr = (struct b43_txhdr *)_txhdr;
189 const struct b43_phy *phy = &dev->phy;
190 const struct ieee80211_hdr *wlhdr =
191 (const struct ieee80211_hdr *)fragment_data;
192 int use_encryption = !!info->control.hw_key;
193 __le16 fctl = wlhdr->frame_control;
194 struct ieee80211_rate *fbrate;
196 int rate_ofdm, rate_fb_ofdm;
197 unsigned int plcp_fragment_len;
201 struct ieee80211_rate *txrate;
202 struct ieee80211_tx_rate *rates;
204 memset(txhdr, 0, sizeof(*txhdr));
206 txrate = ieee80211_get_tx_rate(dev->wl->hw, info);
207 rate = txrate ? txrate->hw_value : B43_CCK_RATE_1MB;
208 rate_ofdm = b43_is_ofdm_rate(rate);
209 fbrate = ieee80211_get_alt_retry_rate(dev->wl->hw, info, 0) ? : txrate;
210 rate_fb = fbrate->hw_value;
211 rate_fb_ofdm = b43_is_ofdm_rate(rate_fb);
214 txhdr->phy_rate = b43_plcp_get_ratecode_ofdm(rate);
216 txhdr->phy_rate = b43_plcp_get_ratecode_cck(rate);
217 txhdr->mac_frame_ctl = wlhdr->frame_control;
218 memcpy(txhdr->tx_receiver, wlhdr->addr1, 6);
220 /* Calculate duration for fallback rate */
221 if ((rate_fb == rate) ||
222 (wlhdr->duration_id & cpu_to_le16(0x8000)) ||
223 (wlhdr->duration_id == cpu_to_le16(0))) {
224 /* If the fallback rate equals the normal rate or the
225 * dur_id field contains an AID, CFP magic or 0,
226 * use the original dur_id field. */
227 txhdr->dur_fb = wlhdr->duration_id;
229 txhdr->dur_fb = ieee80211_generic_frame_duration(
230 dev->wl->hw, info->control.vif, fragment_len, fbrate);
233 plcp_fragment_len = fragment_len + FCS_LEN;
234 if (use_encryption) {
235 u8 key_idx = info->control.hw_key->hw_key_idx;
240 B43_WARN_ON(key_idx >= dev->max_nr_keys);
241 key = &(dev->key[key_idx]);
243 if (unlikely(!key->keyconf)) {
244 /* This key is invalid. This might only happen
245 * in a short timeframe after machine resume before
246 * we were able to reconfigure keys.
247 * Drop this packet completely. Do not transmit it
248 * unencrypted to avoid leaking information. */
252 /* Hardware appends ICV. */
253 plcp_fragment_len += info->control.hw_key->icv_len;
255 key_idx = b43_kidx_to_fw(dev, key_idx);
256 mac_ctl |= (key_idx << B43_TXH_MAC_KEYIDX_SHIFT) &
258 mac_ctl |= (key->algorithm << B43_TXH_MAC_KEYALG_SHIFT) &
260 wlhdr_len = ieee80211_hdrlen(fctl);
261 iv_len = min((size_t) info->control.hw_key->iv_len,
262 ARRAY_SIZE(txhdr->iv));
263 memcpy(txhdr->iv, ((u8 *) wlhdr) + wlhdr_len, iv_len);
265 if (b43_is_old_txhdr_format(dev)) {
266 b43_generate_plcp_hdr((struct b43_plcp_hdr4 *)(&txhdr->old_format.plcp),
267 plcp_fragment_len, rate);
269 b43_generate_plcp_hdr((struct b43_plcp_hdr4 *)(&txhdr->new_format.plcp),
270 plcp_fragment_len, rate);
272 b43_generate_plcp_hdr((struct b43_plcp_hdr4 *)(&txhdr->plcp_fb),
273 plcp_fragment_len, rate_fb);
275 /* Extra Frame Types */
277 extra_ft |= B43_TXH_EFT_FB_OFDM;
279 extra_ft |= B43_TXH_EFT_FB_CCK;
281 /* Set channel radio code. Note that the micrcode ORs 0x100 to
282 * this value before comparing it to the value in SHM, if this
285 txhdr->chan_radio_code = phy->channel;
287 /* PHY TX Control word */
289 phy_ctl |= B43_TXH_PHY_ENC_OFDM;
291 phy_ctl |= B43_TXH_PHY_ENC_CCK;
292 if (info->control.rates[0].flags & IEEE80211_TX_RC_USE_SHORT_PREAMBLE)
293 phy_ctl |= B43_TXH_PHY_SHORTPRMBL;
295 switch (b43_ieee80211_antenna_sanitize(dev, info->antenna_sel_tx)) {
296 case 0: /* Default */
297 phy_ctl |= B43_TXH_PHY_ANT01AUTO;
299 case 1: /* Antenna 0 */
300 phy_ctl |= B43_TXH_PHY_ANT0;
302 case 2: /* Antenna 1 */
303 phy_ctl |= B43_TXH_PHY_ANT1;
305 case 3: /* Antenna 2 */
306 phy_ctl |= B43_TXH_PHY_ANT2;
308 case 4: /* Antenna 3 */
309 phy_ctl |= B43_TXH_PHY_ANT3;
315 rates = info->control.rates;
317 if (!(info->flags & IEEE80211_TX_CTL_NO_ACK))
318 mac_ctl |= B43_TXH_MAC_ACK;
319 /* use hardware sequence counter as the non-TID counter */
320 if (info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ)
321 mac_ctl |= B43_TXH_MAC_HWSEQ;
322 if (info->flags & IEEE80211_TX_CTL_FIRST_FRAGMENT)
323 mac_ctl |= B43_TXH_MAC_STMSDU;
324 if (phy->type == B43_PHYTYPE_A)
325 mac_ctl |= B43_TXH_MAC_5GHZ;
327 /* Overwrite rates[0].count to make the retry calculation
328 * in the tx status easier. need the actual retry limit to
329 * detect whether the fallback rate was used.
331 if ((rates[0].flags & IEEE80211_TX_RC_USE_RTS_CTS) ||
332 (rates[0].count <= dev->wl->hw->conf.long_frame_max_tx_count)) {
333 rates[0].count = dev->wl->hw->conf.long_frame_max_tx_count;
334 mac_ctl |= B43_TXH_MAC_LONGFRAME;
336 rates[0].count = dev->wl->hw->conf.short_frame_max_tx_count;
339 /* Generate the RTS or CTS-to-self frame */
340 if ((rates[0].flags & IEEE80211_TX_RC_USE_RTS_CTS) ||
341 (rates[0].flags & IEEE80211_TX_RC_USE_CTS_PROTECT)) {
343 struct ieee80211_hdr *hdr;
344 int rts_rate, rts_rate_fb;
345 int rts_rate_ofdm, rts_rate_fb_ofdm;
346 struct b43_plcp_hdr6 *plcp;
347 struct ieee80211_rate *rts_cts_rate;
349 rts_cts_rate = ieee80211_get_rts_cts_rate(dev->wl->hw, info);
351 rts_rate = rts_cts_rate ? rts_cts_rate->hw_value : B43_CCK_RATE_1MB;
352 rts_rate_ofdm = b43_is_ofdm_rate(rts_rate);
353 rts_rate_fb = b43_calc_fallback_rate(rts_rate);
354 rts_rate_fb_ofdm = b43_is_ofdm_rate(rts_rate_fb);
356 if (rates[0].flags & IEEE80211_TX_RC_USE_CTS_PROTECT) {
357 struct ieee80211_cts *cts;
359 if (b43_is_old_txhdr_format(dev)) {
360 cts = (struct ieee80211_cts *)
361 (txhdr->old_format.rts_frame);
363 cts = (struct ieee80211_cts *)
364 (txhdr->new_format.rts_frame);
366 ieee80211_ctstoself_get(dev->wl->hw, info->control.vif,
367 fragment_data, fragment_len,
369 mac_ctl |= B43_TXH_MAC_SENDCTS;
370 len = sizeof(struct ieee80211_cts);
372 struct ieee80211_rts *rts;
374 if (b43_is_old_txhdr_format(dev)) {
375 rts = (struct ieee80211_rts *)
376 (txhdr->old_format.rts_frame);
378 rts = (struct ieee80211_rts *)
379 (txhdr->new_format.rts_frame);
381 ieee80211_rts_get(dev->wl->hw, info->control.vif,
382 fragment_data, fragment_len,
384 mac_ctl |= B43_TXH_MAC_SENDRTS;
385 len = sizeof(struct ieee80211_rts);
389 /* Generate the PLCP headers for the RTS/CTS frame */
390 if (b43_is_old_txhdr_format(dev))
391 plcp = &txhdr->old_format.rts_plcp;
393 plcp = &txhdr->new_format.rts_plcp;
394 b43_generate_plcp_hdr((struct b43_plcp_hdr4 *)plcp,
396 plcp = &txhdr->rts_plcp_fb;
397 b43_generate_plcp_hdr((struct b43_plcp_hdr4 *)plcp,
400 if (b43_is_old_txhdr_format(dev)) {
401 hdr = (struct ieee80211_hdr *)
402 (&txhdr->old_format.rts_frame);
404 hdr = (struct ieee80211_hdr *)
405 (&txhdr->new_format.rts_frame);
407 txhdr->rts_dur_fb = hdr->duration_id;
410 extra_ft |= B43_TXH_EFT_RTS_OFDM;
411 txhdr->phy_rate_rts =
412 b43_plcp_get_ratecode_ofdm(rts_rate);
414 extra_ft |= B43_TXH_EFT_RTS_CCK;
415 txhdr->phy_rate_rts =
416 b43_plcp_get_ratecode_cck(rts_rate);
418 if (rts_rate_fb_ofdm)
419 extra_ft |= B43_TXH_EFT_RTSFB_OFDM;
421 extra_ft |= B43_TXH_EFT_RTSFB_CCK;
425 if (b43_is_old_txhdr_format(dev))
426 txhdr->old_format.cookie = cpu_to_le16(cookie);
428 txhdr->new_format.cookie = cpu_to_le16(cookie);
430 /* Apply the bitfields */
431 txhdr->mac_ctl = cpu_to_le32(mac_ctl);
432 txhdr->phy_ctl = cpu_to_le16(phy_ctl);
433 txhdr->extra_ft = extra_ft;
438 static s8 b43_rssi_postprocess(struct b43_wldev *dev,
439 u8 in_rssi, int ofdm,
440 int adjust_2053, int adjust_2050)
442 struct b43_phy *phy = &dev->phy;
443 struct b43_phy_g *gphy = phy->g;
446 switch (phy->radio_ver) {
459 if (dev->dev->bus->sprom.
460 boardflags_lo & B43_BFL_RSSI) {
463 B43_WARN_ON(phy->type != B43_PHYTYPE_G);
464 tmp = gphy->nrssi_lt[in_rssi];
476 if (phy->type == B43_PHYTYPE_G && adjust_2050)
502 static s8 b43_rssinoise_postprocess(struct b43_wldev *dev, u8 in_rssi)
504 struct b43_phy *phy = &dev->phy;
507 if (phy->type == B43_PHYTYPE_A) {
508 //TODO: Incomplete specs.
511 ret = b43_rssi_postprocess(dev, in_rssi, 0, 1, 1);
517 void b43_rx(struct b43_wldev *dev, struct sk_buff *skb, const void *_rxhdr)
519 struct ieee80211_rx_status status;
520 struct b43_plcp_hdr6 *plcp;
521 struct ieee80211_hdr *wlhdr;
522 const struct b43_rxhdr_fw4 *rxhdr = _rxhdr;
524 u16 phystat0, phystat3, chanstat, mactime;
530 memset(&status, 0, sizeof(status));
532 /* Get metadata about the frame from the header. */
533 phystat0 = le16_to_cpu(rxhdr->phy_status0);
534 phystat3 = le16_to_cpu(rxhdr->phy_status3);
535 macstat = le32_to_cpu(rxhdr->mac_status);
536 mactime = le16_to_cpu(rxhdr->mac_time);
537 chanstat = le16_to_cpu(rxhdr->channel);
538 phytype = chanstat & B43_RX_CHAN_PHYTYPE;
540 if (unlikely(macstat & B43_RX_MAC_FCSERR)) {
541 dev->wl->ieee_stats.dot11FCSErrorCount++;
542 status.flag |= RX_FLAG_FAILED_FCS_CRC;
544 if (unlikely(phystat0 & (B43_RX_PHYST0_PLCPHCF | B43_RX_PHYST0_PLCPFV)))
545 status.flag |= RX_FLAG_FAILED_PLCP_CRC;
546 if (phystat0 & B43_RX_PHYST0_SHORTPRMBL)
547 status.flag |= RX_FLAG_SHORTPRE;
548 if (macstat & B43_RX_MAC_DECERR) {
549 /* Decryption with the given key failed.
550 * Drop the packet. We also won't be able to decrypt it with
551 * the key in software. */
555 /* Skip PLCP and padding */
556 padding = (macstat & B43_RX_MAC_PADDING) ? 2 : 0;
557 if (unlikely(skb->len < (sizeof(struct b43_plcp_hdr6) + padding))) {
558 b43dbg(dev->wl, "RX: Packet size underrun (1)\n");
561 plcp = (struct b43_plcp_hdr6 *)(skb->data + padding);
562 skb_pull(skb, sizeof(struct b43_plcp_hdr6) + padding);
563 /* The skb contains the Wireless Header + payload data now */
564 if (unlikely(skb->len < (2 + 2 + 6 /*minimum hdr */ + FCS_LEN))) {
565 b43dbg(dev->wl, "RX: Packet size underrun (2)\n");
568 wlhdr = (struct ieee80211_hdr *)(skb->data);
569 fctl = wlhdr->frame_control;
571 if (macstat & B43_RX_MAC_DEC) {
575 keyidx = ((macstat & B43_RX_MAC_KEYIDX)
576 >> B43_RX_MAC_KEYIDX_SHIFT);
577 /* We must adjust the key index here. We want the "physical"
578 * key index, but the ucode passed it slightly different.
580 keyidx = b43_kidx_to_raw(dev, keyidx);
581 B43_WARN_ON(keyidx >= dev->max_nr_keys);
583 if (dev->key[keyidx].algorithm != B43_SEC_ALGO_NONE) {
584 wlhdr_len = ieee80211_hdrlen(fctl);
585 if (unlikely(skb->len < (wlhdr_len + 3))) {
587 "RX: Packet size underrun (3)\n");
590 status.flag |= RX_FLAG_DECRYPTED;
594 /* Link quality statistics */
595 status.noise = dev->stats.link_noise;
596 if ((chanstat & B43_RX_CHAN_PHYTYPE) == B43_PHYTYPE_N) {
597 // s8 rssi = max(rxhdr->power0, rxhdr->power1);
598 //TODO: Find out what the rssi value is (dBm or percentage?)
599 // and also find out what the maximum possible value is.
600 // Fill status.ssi and status.signal fields.
602 status.signal = b43_rssi_postprocess(dev, rxhdr->jssi,
603 (phystat0 & B43_RX_PHYST0_OFDM),
604 (phystat0 & B43_RX_PHYST0_GAINCTL),
605 (phystat3 & B43_RX_PHYST3_TRSTATE));
606 status.qual = (rxhdr->jssi * 100) / B43_RX_MAX_SSI;
609 if (phystat0 & B43_RX_PHYST0_OFDM)
610 status.rate_idx = b43_plcp_get_bitrate_idx_ofdm(plcp,
611 phytype == B43_PHYTYPE_A);
613 status.rate_idx = b43_plcp_get_bitrate_idx_cck(plcp);
614 if (unlikely(status.rate_idx == -1)) {
615 /* PLCP seems to be corrupted.
616 * Drop the frame, if we are not interested in corrupted frames. */
617 if (!(dev->wl->filter_flags & FIF_PLCPFAIL))
620 status.antenna = !!(phystat0 & B43_RX_PHYST0_ANT);
623 * All frames on monitor interfaces and beacons always need a full
624 * 64-bit timestamp. Monitor interfaces need it for diagnostic
625 * purposes and beacons for IBSS merging.
626 * This code assumes we get to process the packet within 16 bits
627 * of timestamp, i.e. about 65 milliseconds after the PHY received
630 if (ieee80211_is_beacon(fctl) || dev->wl->radiotap_enabled) {
633 b43_tsf_read(dev, &status.mactime);
634 low_mactime_now = status.mactime;
635 status.mactime = status.mactime & ~0xFFFFULL;
636 status.mactime += mactime;
637 if (low_mactime_now <= mactime)
638 status.mactime -= 0x10000;
639 status.flag |= RX_FLAG_TSFT;
642 chanid = (chanstat & B43_RX_CHAN_ID) >> B43_RX_CHAN_ID_SHIFT;
643 switch (chanstat & B43_RX_CHAN_PHYTYPE) {
645 status.band = IEEE80211_BAND_5GHZ;
647 /* FIXME: We don't really know which value the "chanid" contains.
648 * So the following assignment might be wrong. */
649 status.freq = b43_channel_to_freq_5ghz(chanid);
652 status.band = IEEE80211_BAND_2GHZ;
653 /* chanid is the radio channel cookie value as used
654 * to tune the radio. */
655 status.freq = chanid + 2400;
658 /* chanid is the SHM channel cookie. Which is the plain
659 * channel number in b43. */
660 if (chanstat & B43_RX_CHAN_5GHZ) {
661 status.band = IEEE80211_BAND_5GHZ;
662 status.freq = b43_freq_to_channel_5ghz(chanid);
664 status.band = IEEE80211_BAND_2GHZ;
665 status.freq = b43_freq_to_channel_2ghz(chanid);
673 ieee80211_rx_irqsafe(dev->wl->hw, skb, &status);
677 b43dbg(dev->wl, "RX: Packet dropped\n");
678 dev_kfree_skb_any(skb);
681 void b43_handle_txstatus(struct b43_wldev *dev,
682 const struct b43_txstatus *status)
684 b43_debugfs_log_txstat(dev, status);
686 if (status->intermediate)
688 if (status->for_ampdu)
691 dev->wl->ieee_stats.dot11ACKFailureCount++;
692 if (status->rts_count) {
693 if (status->rts_count == 0xF) //FIXME
694 dev->wl->ieee_stats.dot11RTSFailureCount++;
696 dev->wl->ieee_stats.dot11RTSSuccessCount++;
699 if (b43_using_pio_transfers(dev))
700 b43_pio_handle_txstatus(dev, status);
702 b43_dma_handle_txstatus(dev, status);
704 b43_phy_txpower_check(dev, 0);
707 /* Fill out the mac80211 TXstatus report based on the b43-specific
708 * txstatus report data. This returns a boolean whether the frame was
709 * successfully transmitted. */
710 bool b43_fill_txstatus_report(struct b43_wldev *dev,
711 struct ieee80211_tx_info *report,
712 const struct b43_txstatus *status)
714 bool frame_success = 1;
717 /* preserve the confiured retry limit before clearing the status
718 * The xmit function has overwritten the rc's value with the actual
719 * retry limit done by the hardware */
720 retry_limit = report->status.rates[0].count;
721 ieee80211_tx_info_clear_status(report);
724 /* The frame was ACKed. */
725 report->flags |= IEEE80211_TX_STAT_ACK;
727 /* The frame was not ACKed... */
728 if (!(report->flags & IEEE80211_TX_CTL_NO_ACK)) {
729 /* ...but we expected an ACK. */
733 if (status->frame_count == 0) {
734 /* The frame was not transmitted at all. */
735 report->status.rates[0].count = 0;
736 } else if (status->rts_count > dev->wl->hw->conf.short_frame_max_tx_count) {
738 * If the short retries (RTS, not data frame) have exceeded
739 * the limit, the hw will not have tried the selected rate,
740 * but will have used the fallback rate instead.
741 * Don't let the rate control count attempts for the selected
742 * rate in this case, otherwise the statistics will be off.
744 report->status.rates[0].count = 0;
745 report->status.rates[1].count = status->frame_count;
747 if (status->frame_count > retry_limit) {
748 report->status.rates[0].count = retry_limit;
749 report->status.rates[1].count = status->frame_count -
753 report->status.rates[0].count = status->frame_count;
754 report->status.rates[1].idx = -1;
758 return frame_success;
761 /* Stop any TX operation on the device (suspend the hardware queues) */
762 void b43_tx_suspend(struct b43_wldev *dev)
764 if (b43_using_pio_transfers(dev))
765 b43_pio_tx_suspend(dev);
767 b43_dma_tx_suspend(dev);
770 /* Resume any TX operation on the device (resume the hardware queues) */
771 void b43_tx_resume(struct b43_wldev *dev)
773 if (b43_using_pio_transfers(dev))
774 b43_pio_tx_resume(dev);
776 b43_dma_tx_resume(dev);