brcm80211: smac: remove usage of brcmu_pkttotlen
The function brcmu_pkttotlen calculates the total length of a sk_buff chain following the next pointer. In brcmsmac this is not needed as in each place where it was used the provided sk_buff had a NULL pointer as next field value. Reviewed-by: Alwin Beukers <alwin@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
122d36fd5a
commit
ad4d71f69e
2 changed files with 4 additions and 6 deletions
|
@ -649,7 +649,7 @@ brcms_c_sendampdu(struct ampdu_info *ampdu, struct brcms_txq_info *qi,
|
||||||
len = roundup(len, 4);
|
len = roundup(len, 4);
|
||||||
ampdu_len += (len + (ndelim + 1) * AMPDU_DELIMITER_LEN);
|
ampdu_len += (len + (ndelim + 1) * AMPDU_DELIMITER_LEN);
|
||||||
|
|
||||||
dma_len += (u16) brcmu_pkttotlen(p);
|
dma_len += (u16) p->len;
|
||||||
|
|
||||||
BCMMSG(wlc->wiphy, "wl%d: ampdu_len %d"
|
BCMMSG(wlc->wiphy, "wl%d: ampdu_len %d"
|
||||||
" seg_cnt %d null delim %d\n",
|
" seg_cnt %d null delim %d\n",
|
||||||
|
@ -741,9 +741,7 @@ brcms_c_sendampdu(struct ampdu_info *ampdu, struct brcms_txq_info *qi,
|
||||||
if (p) {
|
if (p) {
|
||||||
if ((tx_info->flags & IEEE80211_TX_CTL_AMPDU) &&
|
if ((tx_info->flags & IEEE80211_TX_CTL_AMPDU) &&
|
||||||
((u8) (p->priority) == tid)) {
|
((u8) (p->priority) == tid)) {
|
||||||
|
plen = p->len + AMPDU_MAX_MPDU_OVERHEAD;
|
||||||
plen = brcmu_pkttotlen(p) +
|
|
||||||
AMPDU_MAX_MPDU_OVERHEAD;
|
|
||||||
plen = max(scb_ampdu->min_len, plen);
|
plen = max(scb_ampdu->min_len, plen);
|
||||||
|
|
||||||
if ((plen + ampdu_len) > max_ampdu_bytes) {
|
if ((plen + ampdu_len) > max_ampdu_bytes) {
|
||||||
|
|
|
@ -949,7 +949,7 @@ brcms_c_dotxstatus(struct brcms_c_info *wlc, struct tx_status *txs)
|
||||||
tx_info->flags |= IEEE80211_TX_STAT_ACK;
|
tx_info->flags |= IEEE80211_TX_STAT_ACK;
|
||||||
}
|
}
|
||||||
|
|
||||||
totlen = brcmu_pkttotlen(p);
|
totlen = p->len;
|
||||||
free_pdu = true;
|
free_pdu = true;
|
||||||
|
|
||||||
brcms_c_txfifo_complete(wlc, queue, 1);
|
brcms_c_txfifo_complete(wlc, queue, 1);
|
||||||
|
@ -6716,7 +6716,7 @@ brcms_c_d11hdrs_mac80211(struct brcms_c_info *wlc, struct ieee80211_hw *hw,
|
||||||
qos = ieee80211_is_data_qos(h->frame_control);
|
qos = ieee80211_is_data_qos(h->frame_control);
|
||||||
|
|
||||||
/* compute length of frame in bytes for use in PLCP computations */
|
/* compute length of frame in bytes for use in PLCP computations */
|
||||||
len = brcmu_pkttotlen(p);
|
len = p->len;
|
||||||
phylen = len + FCS_LEN;
|
phylen = len + FCS_LEN;
|
||||||
|
|
||||||
/* Get tx_info */
|
/* Get tx_info */
|
||||||
|
|
Loading…
Reference in a new issue