[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20181220081130.GB3581@gauss3.secunet.de>
Date: Thu, 20 Dec 2018 09:11:30 +0100
From: Steffen Klassert <steffen.klassert@...unet.com>
To: YueHaibing <yuehaibing@...wei.com>
CC: <davem@...emloft.net>, <herbert@...dor.apana.org.au>,
<kuznet@....inr.ac.ru>, <yoshfuji@...ux-ipv6.org>,
<linux-kernel@...r.kernel.org>, <netdev@...r.kernel.org>
Subject: Re: [PATCH net-next] xfrm6_tunnel: Fix spi check in
__xfrm6_tunnel_alloc_spi
On Wed, Dec 19, 2018 at 02:45:09PM +0800, YueHaibing wrote:
> gcc warn this:
>
> net/ipv6/xfrm6_tunnel.c:143 __xfrm6_tunnel_alloc_spi() warn:
> always true condition '(spi <= 4294967295) => (0-u32max <= u32max)'
>
> 'spi' is u32, which always not greater than XFRM6_TUNNEL_SPI_MAX
> because of wrap around. So the second forloop will never reach.
>
> Signed-off-by: YueHaibing <yuehaibing@...wei.com>
Also applied, thanks a lot!
Powered by blists - more mailing lists