net/mlx5: Store counters in rbtree instead of list
In order to use bulk counters, we need to have counters sorted by id. Signed-off-by: Amir Vadai <amir@vadai.me> Reviewed-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
18017723d6
commit
29cc667907
@@ -469,7 +469,7 @@ struct mlx5_irq_info {
|
||||
};
|
||||
|
||||
struct mlx5_fc_stats {
|
||||
struct list_head list;
|
||||
struct rb_root counters;
|
||||
struct list_head addlist;
|
||||
/* protect addlist add/splice operations */
|
||||
spinlock_t addlist_lock;
|
||||
|
Reference in New Issue
Block a user