]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5e: Refactor neigh used value update for concurrent execution
authorVlad Buslov <vladbu@mellanox.com>
Sat, 3 Aug 2019 18:43:06 +0000 (21:43 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Wed, 21 Aug 2019 22:55:17 +0000 (15:55 -0700)
commit96d6cbae73821efcaa7f4462296ff6a426d3244a
tree8e1525686cffc7f57e215acf9b4542277228c862
parent35cb0c54d74499d43be7cf900ecc42e7e56915fa
net/mlx5e: Refactor neigh used value update for concurrent execution

In order to remove dependency on rtnl lock and allow neigh used value
update workqueue task to execute concurrently with tc, refactor
mlx5e_tc_update_neigh_used_value() for concurrent execution:

- Lock encap table when accessing encap entry to prevent concurrent
  changes.

- Save offloaded encap flows to temporary list and release them after encap
  entry is updated. Add mlx5e_put_encap_flow_list() helper which is
  intended to be shared with neigh update code in following patch in this
  series. This is necessary because mlx5e_flow_put() can't be called while
  holding encap_tbl_lock.

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