[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1474380711.23058.8.camel@edumazet-glaptop3.roam.corp.google.com>
Date: Tue, 20 Sep 2016 07:11:51 -0700
From: Eric Dumazet <eric.dumazet@...il.com>
To: Jiri Pirko <jiri@...nulli.us>
Cc: netdev@...r.kernel.org
Subject: Re: UBSAN reports issue in ip_idents_reserve
On Tue, 2016-09-20 at 15:39 +0200, Jiri Pirko wrote:
> I see. So how to silent the warning?
>
We can replace the atomic_add_return() and use a loop around
atomic_read() and atomic_cmpxhg()
This would change the nice property of x86 xadd into a loop.
Or we also could fallback to random generation if the atomic_cmpxchg()
fails.
I'll provide a patch, thanks.
Powered by blists - more mailing lists