brcmfmac: fix sdio sending of large buffers.
authorHante Meuleman <meuleman@broadcom.com>
Wed, 29 Jan 2014 14:32:16 +0000 (15:32 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 12 Feb 2014 20:31:50 +0000 (15:31 -0500)
the function brcmf_sdiod_ramrw is supposed to be able to send
large blobs of data. However inside the loop the skb->len field
did not correctly get reset each round. As a result only small
blobs could be sent. This patch fixes this problem.

Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Daniel (Deognyoun) Kim <dekim@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>
drivers/net/wireless/brcm80211/brcmfmac/bcmsdh.c

index 5711fd6..07e7d25 100644 (file)
@@ -826,7 +826,7 @@ brcmf_sdiod_ramrw(struct brcmf_sdio_dev *sdiodev, bool write, u32 address,
                }
                if (!write)
                        memcpy(data, pkt->data, dsize);
-               skb_trim(pkt, dsize);
+               skb_trim(pkt, 0);
 
                /* Adjust for next transfer (if any) */
                size -= dsize;