Re: [PATCH net] net: reject dev_weight products that overflow int
From: Jakub Kicinski
Date: Fri Oct 23 2026 - 15:31:45 EST
On Fri, 23 Oct 2026 19:42:25 +0800 Jiayuan Chen wrote:
> proc_do_dev_weight() sets the backlog NAPI weight and the qdisc quota
> to dev_weight * dev_weight_rx_bias and dev_weight * dev_weight_tx_bias.
> The three sysctls only have a lower bound of 1, so the products can
> overflow int and end up <= 0, e.g. dev_weight=65536 and
> dev_weight_rx_bias=65536 give a backlog weight of 0.
Not sure anyone uses these, maybe we could cap them?
1k for dev weight 8 for bias?