[dpdk-dev] [PATCH] net/ice: fix integer overflow when computing max_pkt_len
Zhang, Qi Z
qi.z.zhang at intel.com
Mon Jun 21 06:20:13 CEST 2021
> -----Original Message-----
> From: Tudor Cornea <tudor.cornea.keysight at gmail.com>
> Sent: Tuesday, June 15, 2021 6:39 PM
> To: Yang, Qiming <qiming.yang at intel.com>; Zhang, Qi Z
> <qi.z.zhang at intel.com>
> Cc: dev at dpdk.org; Tudor Cornea <tudor.cornea at keysight.com>
> Subject: [PATCH] net/ice: fix integer overflow when computing max_pkt_len
>
> The len variable, used in the computation of max_pkt_len could overflow, if
> used to store the result of the following computation:
>
> ICE_SUPPORT_CHAIN_NUM * rxq->rx_buf_len
>
> Since, we could define the mbuf size to have a large value (i.e 13312), and
> ICE_SUPPORT_CHAIN_NUM is defined as 5, the computation mentioned above
> could potentially result in a value which might be bigger than MAX_USHORT.
>
> The result will be that Jumbo Frames will not work properly
>
> Signed-off-by: Tudor Cornea <tudor.cornea at keysight.com>
Acked-by: Qi Zhang <qi.z.zhang at intel.com>
Applied to dpdk-next-net-intel after adding missing fixline and cc stable
Fixes: 1b009275e2c8 ("net/ice: add Rx queue init in DCF")
Cc: stable at dpdk.org
Thanks
Qi
More information about the dev
mailing list