net/mlx5e: Protect unready flows with dedicated lock
authorVlad Buslov <vladbu@mellanox.com>
Wed, 13 Mar 2019 17:50:24 +0000 (19:50 +0200)
committerSaeed Mahameed <saeedm@mellanox.com>
Mon, 29 Jul 2019 23:40:25 +0000 (16:40 -0700)
commitad86755b18d5edf1956f6d25c844f27289216877
tree4d241e7ac4920899881468fe17443e303285f408
parentc5d326b29603bad4e5342801414b7302ba010209
net/mlx5e: Protect unready flows with dedicated lock

In order to remove dependency on rtnl lock for protecting unready_flows
list when reoffloading unready flows on workqueue, extend representor
uplink private structure with dedicated 'unready_flows_lock' mutex. Take
the lock in all users of unready_flows list before accessing it. Implement
helper functions to add and delete unready flow.

Signed-off-by: Vlad Buslov <vladbu@mellanox.com>
Reviewed-by: Jianbo Liu <jianbol@mellanox.com>
Reviewed-by: Roi Dayan <roid@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
drivers/net/ethernet/mellanox/mlx5/core/en_rep.h
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c