OSDN Git Service

brcmfmac: Fix bug in flowring management.
authorHante Meuleman <meuleman@broadcom.com>
Fri, 18 Sep 2015 20:08:09 +0000 (22:08 +0200)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 29 Sep 2015 07:55:52 +0000 (10:55 +0300)
The hash index stored in the flowrings is of type u16 but gets
stored in u8. This can result in incorrect indexing and possibly
result in crashes. This patch fixes the type.

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: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/brcm80211/brcmfmac/flowring.h

index 5551861..95fd1c9 100644 (file)
@@ -34,7 +34,7 @@ enum ring_status {
 };
 
 struct brcmf_flowring_ring {
-       u8 hash_id;
+       u16 hash_id;
        bool blocked;
        enum ring_status status;
        struct sk_buff_head skblist;