net/mlx5e: Add a lock on tir list
Refresh tirs is looping over a global list of tirs while netdevs are
adding and removing tirs from that list. That is why a lock is
required.
Fixes: 724b2aa151
("net/mlx5e: TIRs management refactoring")
Signed-off-by: Yuval Avnery <yuvalav@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
This commit is contained in:

committed by
Saeed Mahameed

parent
8e949363f0
commit
80a2a9026b
@@ -594,6 +594,8 @@ enum mlx5_pagefault_type_flags {
|
||||
};
|
||||
|
||||
struct mlx5_td {
|
||||
/* protects tirs list changes while tirs refresh */
|
||||
struct mutex list_lock;
|
||||
struct list_head tirs_list;
|
||||
u32 tdn;
|
||||
};
|
||||
|
Reference in New Issue
Block a user