Skip to content

Commit 2785851

Browse files
pinkperfectKalle Valo
authored andcommitted
wifi: mwifiex: Fix missed return in oob checks failed path
Add missed return in mwifiex_uap_queue_bridged_pkt() and mwifiex_process_rx_packet(). Fixes: 1195852 ("wifi: mwifiex: Fix OOB and integer underflow when rx packets") Signed-off-by: Polaris Pi <pinkperfect2021@gmail.com> Reported-by: Dmitry Antipov <dmantipov@yandex.ru> Acked-by: Brian Norris <briannorris@chromium.org> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://lore.kernel.org/r/20230810083911.3725248-1-pinkperfect2021@gmail.com
1 parent a9be186 commit 2785851

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

drivers/net/wireless/marvell/mwifiex/sta_rx.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ int mwifiex_process_rx_packet(struct mwifiex_private *priv,
9292
skb->len, rx_pkt_off);
9393
priv->stats.rx_dropped++;
9494
dev_kfree_skb_any(skb);
95+
return -1;
9596
}
9697

9798
if ((!memcmp(&rx_pkt_hdr->rfc1042_hdr, bridge_tunnel_header,

drivers/net/wireless/marvell/mwifiex/uap_txrx.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ static void mwifiex_uap_queue_bridged_pkt(struct mwifiex_private *priv,
110110
skb->len, le16_to_cpu(uap_rx_pd->rx_pkt_offset));
111111
priv->stats.rx_dropped++;
112112
dev_kfree_skb_any(skb);
113+
return;
113114
}
114115

115116
if ((!memcmp(&rx_pkt_hdr->rfc1042_hdr, bridge_tunnel_header,

0 commit comments

Comments
 (0)