Subject: Re: [PATCH net-next 3/4] ethtool: strset: check nla_len overflow before nla_nest_end

From: Jakub Kicinski <[email-masked]>
Date: Tue, 31 Mar 2026 18:46:37 -0700

On Tue, 31 Mar 2026 11:56:13 +0800 Hangbin Liu wrote:
> +		if (skb_tail_pointer(skb) - (unsigned char *)strings_attr > U16_MAX)
> +			goto nla_put_failure;

bit ugly, let's add a variant of nla_nest_end() which can return 
an error on overflow (without the warning from patch 4) ?

> +
>  		nla_nest_end(skb, strings_attr);