[PATCH net-next 0/2] net: stmmac: sanitise stmmac_is_jumbo_frm()
Russell King (Oracle)
linux at armlinux.org.uk
Tue Nov 18 02:00:08 PST 2025
stmmac_is_jumbo_frm() takes skb->len, which is unsigned int, but the
parameter is passed as an "int" and then tested using signed
comparisons. This can cause bugs. Change the parameter to be unsigned.
Also arrange for it to return a bool.
drivers/net/ethernet/stmicro/stmmac/chain_mode.c | 9 ++++-----
drivers/net/ethernet/stmicro/stmmac/hwif.h | 2 +-
drivers/net/ethernet/stmicro/stmmac/ring_mode.c | 9 ++-------
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 6 +++---
4 files changed, 10 insertions(+), 16 deletions(-)
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!
More information about the linux-arm-kernel
mailing list