]> git.baikalelectronics.ru Git - kernel.git/commit
net: ethernet: mtk_eth_soc: check max allowed hash in mtk_ppe_check_skb
authorLorenzo Bianconi <lorenzo@kernel.org>
Mon, 5 Sep 2022 12:41:28 +0000 (14:41 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 7 Sep 2022 14:29:40 +0000 (15:29 +0100)
commit55aefaf9c44436597b3d2487045651d00af51961
tree557502d19c546f2bdf52775208b5d271a9a3b9df
parent056ca9e464a5779e9932d97e07d5015f56ec048d
net: ethernet: mtk_eth_soc: check max allowed hash in mtk_ppe_check_skb

Even if max hash configured in hw in mtk_ppe_hash_entry is
MTK_PPE_ENTRIES - 1, check theoretical OOB accesses in
mtk_ppe_check_skb routine

Fixes: 8051684039d5e ("net: ethernet: mtk_eth_soc: rework hardware flow table management")
Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mediatek/mtk_ppe.h