]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5: IPSec, Fix the SA context hash key
authorRaed Salem <raeds@mellanox.com>
Thu, 18 Oct 2018 05:55:21 +0000 (08:55 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Mon, 19 Nov 2018 22:35:04 +0000 (14:35 -0800)
commitd8b516105389cd829dbf3e5cfa90ddf672beafc6
tree83059e83660cca784f62d3f80e02968c03e31b9f
parenta9e80a095d95d1159b26f73bd6d9c2fadc7fb411
net/mlx5: IPSec, Fix the SA context hash key

The commit "net/mlx5: Refactor accel IPSec code" introduced a
bug where asynchronous short time change in hash key value
by create/release SA context might happen during an asynchronous
hash resize operation this could cause a subsequent remove SA
context operation to fail as the key value used during resize is
not the same key value used when remove SA context operation is
invoked.

This commit fixes the bug by defining the SA context hash key
such that it includes only fields that never change during the
lifetime of the SA context object.

Fixes: fc4f3d9a9628 ("net/mlx5: Refactor accel IPSec code")
Signed-off-by: Raed Salem <raeds@mellanox.com>
Reviewed-by: Aviad Yehezkel <aviadye@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c