diff options
author | Hante Meuleman <meuleman@broadcom.com> | 2012-09-11 15:18:50 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-09-12 14:19:16 -0400 |
commit | 64477ebc326d30f1680898f073a958e9e8e5a1e5 (patch) | |
tree | 9bc3d78dce363b9cad4a0c8a8e071f5adca04300 | |
parent | 35aafa9d6f977bff95c226d12435795086bc820d (diff) |
brcmfmac: refill buffers on rx protocol error.
This patch fixes a bug where rx buffer does not get refilled if the
packet received has an rx protocol error.
Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Signed-off-by: Hante Meuleman <meuleman@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmfmac/usb.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/wireless/brcm80211/brcmfmac/usb.c b/drivers/net/wireless/brcm80211/brcmfmac/usb.c index 8aab2a22d6a1..6e3ff6f61103 100644 --- a/drivers/net/wireless/brcm80211/brcmfmac/usb.c +++ b/drivers/net/wireless/brcm80211/brcmfmac/usb.c | |||
@@ -552,12 +552,10 @@ static void brcmf_usb_rx_complete(struct urb *urb) | |||
552 | if (brcmf_proto_hdrpull(devinfo->dev, &ifidx, skb) != 0) { | 552 | if (brcmf_proto_hdrpull(devinfo->dev, &ifidx, skb) != 0) { |
553 | brcmf_dbg(ERROR, "rx protocol error\n"); | 553 | brcmf_dbg(ERROR, "rx protocol error\n"); |
554 | brcmu_pkt_buf_free_skb(skb); | 554 | brcmu_pkt_buf_free_skb(skb); |
555 | brcmf_usb_enq(devinfo, &devinfo->rx_freeq, req, NULL); | ||
556 | devinfo->bus_pub.bus->dstats.rx_errors++; | 555 | devinfo->bus_pub.bus->dstats.rx_errors++; |
557 | } else { | 556 | } else |
558 | brcmf_rx_packet(devinfo->dev, ifidx, skb); | 557 | brcmf_rx_packet(devinfo->dev, ifidx, skb); |
559 | brcmf_usb_rx_refill(devinfo, req); | 558 | brcmf_usb_rx_refill(devinfo, req); |
560 | } | ||
561 | } else { | 559 | } else { |
562 | brcmu_pkt_buf_free_skb(skb); | 560 | brcmu_pkt_buf_free_skb(skb); |
563 | brcmf_usb_enq(devinfo, &devinfo->rx_freeq, req, NULL); | 561 | brcmf_usb_enq(devinfo, &devinfo->rx_freeq, req, NULL); |