[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANn89iLYS9QXG7YVJ=DSCedQ5670Kps6dUuh1duaeZuYamM_Rw@mail.gmail.com>
Date: Fri, 26 Apr 2024 18:02:45 +0200
From: Eric Dumazet <edumazet@...gle.com>
To: Guillaume Nault <gnault@...hat.com>
Cc: David Miller <davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>, netdev@...r.kernel.org,
Ido Schimmel <idosch@...dia.com>, Amit Cohen <amcohen@...dia.com>, Petr Machata <petrm@...dia.com>,
Nikolay Aleksandrov <razor@...ckwall.org>, Jiri Benc <jbenc@...hat.com>, Breno Leitao <leitao@...ian.org>,
Roopa Prabhu <roopa@...dia.com>, stephen hemminger <shemminger@...tta.com>
Subject: Re: [PATCH net 1/2] vxlan: Fix racy device stats updates.
On Fri, Apr 26, 2024 at 5:27 PM Guillaume Nault <gnault@...hat.com> wrote:
>
> VXLAN devices update their stats locklessly. Therefore these counters
> should either be stored in per-cpu data structures or the updates
> should be done using atomic increments.
>
> Since the net_device_core_stats infrastructure is already used in
> vxlan_rcv(), use it for the other rx_dropped and tx_dropped counter
> updates. Update the other counters atomically using DEV_STATS_INC().
>
> Fixes: d342894c5d2f ("vxlan: virtual extensible lan")
> Signed-off-by: Guillaume Nault <gnault@...hat.com>
> ---
Reviewed-by: Eric Dumazet <edumazet@...gle.com>
Powered by blists - more mailing lists