From: Hante Meuleman Date: Tue, 11 Sep 2012 19:18:50 +0000 (+0200) Subject: brcmfmac: refill buffers on rx protocol error. X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=64477ebc326d30f1680898f073a958e9e8e5a1e5;p=openwrt%2Fstaging%2Fblogic.git 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 Signed-off-by: Hante Meuleman Signed-off-by: Arend van Spriel Signed-off-by: John W. Linville --- 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) if (brcmf_proto_hdrpull(devinfo->dev, &ifidx, skb) != 0) { brcmf_dbg(ERROR, "rx protocol error\n"); brcmu_pkt_buf_free_skb(skb); - brcmf_usb_enq(devinfo, &devinfo->rx_freeq, req, NULL); devinfo->bus_pub.bus->dstats.rx_errors++; - } else { + } else brcmf_rx_packet(devinfo->dev, ifidx, skb); - brcmf_usb_rx_refill(devinfo, req); - } + brcmf_usb_rx_refill(devinfo, req); } else { brcmu_pkt_buf_free_skb(skb); brcmf_usb_enq(devinfo, &devinfo->rx_freeq, req, NULL);