Re: [PATCH net-next] net: dsa: mxl862xx: don't read out-of-bounds
From: patchwork-bot+netdevbpf
Date: Fri Mar 20 2026 - 21:42:34 EST
Hello:
This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@xxxxxxxxxx>:
On Wed, 18 Mar 2026 03:07:52 +0000 you wrote:
> The write loop in mxl862xx_api_wrap() computes the word count as
> (size + 1) / 2, rounding up for odd-sized structs.
>
> On the last iteration of an odd-sized buffer it reads a full __le16
> from data[i], accessing one byte past the end of the caller's struct.
> KASAN catches this as a stack-out-of-bounds read during probe (e.g.
> from mxl862xx_bridge_config_fwd() because of the odd length of
> sizeof(struct mxl862xx_bridge_config) == 49).
>
> [...]
Here is the summary with links:
- [net-next] net: dsa: mxl862xx: don't read out-of-bounds
https://git.kernel.org/netdev/net-next/c/6b5f49176a08
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html