brcmfmac: Fix bitmap malloc bug in msgbuf.
authorHante Meuleman <meuleman@broadcom.com>
Wed, 3 Dec 2014 20:05:27 +0000 (21:05 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Thu, 4 Dec 2014 16:35:02 +0000 (11:35 -0500)
Cc: stable@vger.kernel.org # v3.17, v3.18
Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@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/msgbuf.c

index 9f783db34ae5f87b76df083d9e805d3d13f83deb..5b0b70fa1aea845a23f78da891f5ba13b5b9fe36 100644 (file)
@@ -1354,6 +1354,7 @@ int brcmf_proto_msgbuf_attach(struct brcmf_pub *drvr)
        }
        INIT_WORK(&msgbuf->txflow_work, brcmf_msgbuf_txflow_worker);
        count = BITS_TO_LONGS(if_msgbuf->nrof_flowrings);
+       count = count * sizeof(unsigned long);
        msgbuf->flow_map = kzalloc(count, GFP_KERNEL);
        if (!msgbuf->flow_map)
                goto fail;