[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <IA3PR11MB8986B8D2BBB751E4F7DD7412E5C2A@IA3PR11MB8986.namprd11.prod.outlook.com>
Date: Thu, 6 Nov 2025 14:56:55 +0000
From: "Loktionov, Aleksandr" <aleksandr.loktionov@...el.com>
To: "Keller, Jacob E" <jacob.e.keller@...el.com>, "Lobakin, Aleksander"
<aleksander.lobakin@...el.com>, "Nguyen, Anthony L"
<anthony.l.nguyen@...el.com>, "Kitszel, Przemyslaw"
<przemyslaw.kitszel@...el.com>
CC: "intel-wired-lan@...ts.osuosl.org" <intel-wired-lan@...ts.osuosl.org>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: RE: [PATCH iwl-next v2 8/9] ice: shorten ring stat names and add
accessors
> -----Original Message-----
> From: Keller, Jacob E <jacob.e.keller@...el.com>
> Sent: Wednesday, November 5, 2025 10:07 PM
> To: Loktionov, Aleksandr <aleksandr.loktionov@...el.com>; Lobakin,
> Aleksander <aleksander.lobakin@...el.com>; Nguyen, Anthony L
> <anthony.l.nguyen@...el.com>; Kitszel, Przemyslaw
> <przemyslaw.kitszel@...el.com>
> Cc: intel-wired-lan@...ts.osuosl.org; netdev@...r.kernel.org; Keller,
> Jacob E <jacob.e.keller@...el.com>
> Subject: [PATCH iwl-next v2 8/9] ice: shorten ring stat names and add
> accessors
>
> The ice Tx/Rx hotpath has a few statistics counters for tracking
> unexpected events. These values are stored as u64 but are not
> accumulated using the u64_stats API. This could result in load/tear
> stores on some architectures.
> Even some 64-bit architectures could have issues since the fields are
> not read or written using ACCESS_ONCE or READ_ONCE.
>
> A following change is going to refactor the stats accumulator code to
> use the u64_stats API for all of these stats, and to use
> u64_stats_read and u64_stats_inc properly to prevent load/store tears
> on all architectures.
>
> Using u64_stats_inc and the syncp pointer is slightly verbose and
> would be duplicated in a number of places in the Tx and Rx hot path.
> Add accessor macros for the cases where only a single stat value is
> touched at once. To keep lines short, also shorten the stats names and
> convert ice_txq_stats and ice_rxq_stats to struct_group.
>
> This will ease the transition to properly using the u64_stats API in
> the following change.
>
> Signed-off-by: Jacob Keller <jacob.e.keller@...el.com>
> ---
...
> --
> 2.51.0.rc1.197.g6d975e95c9d7
Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@...el.com>
Powered by blists - more mailing lists