Re: [PATCH v3] net/sched: act_skbedit: fix divide-by-zero in tcf_skbedit_hash()
From: patchwork-bot+netdevbpf
Date: Tue Feb 17 2026 - 20:40:30 EST
Hello:
This patch was applied to netdev/net.git (main)
by Jakub Kicinski <kuba@xxxxxxxxxx>:
On Sat, 14 Feb 2026 01:59:48 +0800 you wrote:
> Commit 38a6f0865796 ("net: sched: support hash selecting tx queue")
> added SKBEDIT_F_TXQ_SKBHASH support. The inclusive range size is
> computed as:
>
> mapping_mod = queue_mapping_max - queue_mapping + 1;
>
> The range size can be 65536 when the requested range covers all possible
> u16 queue IDs (e.g. queue_mapping=0 and queue_mapping_max=U16_MAX).
> That value cannot be represented in a u16 and previously wrapped to 0,
> so tcf_skbedit_hash() could trigger a divide-by-zero:
>
> [...]
Here is the summary with links:
- [v3] net/sched: act_skbedit: fix divide-by-zero in tcf_skbedit_hash()
https://git.kernel.org/netdev/net/c/be054cc66f73
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html