Skip to content

Commit 18f38fd

Browse files
rleonklassert
authored andcommitted
net/mlx5e: Improve IPsec flow steering autogroup
Flow steering API separates newly created rules based on their match criteria. Right now, all IPsec tables are created with one group and suffers from not-optimal FS performance. Count number of different match criteria for relevant tables, and set proper value at the table creation. Reviewed-by: Raed Salem <[email protected]> Signed-off-by: Leon Romanovsky <[email protected]> Signed-off-by: Steffen Klassert <[email protected]>
1 parent 6b5c45e commit 18f38fd

File tree

1 file changed

+4
-4
lines changed
  • drivers/net/ethernet/mellanox/mlx5/core/en_accel

1 file changed

+4
-4
lines changed

drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec_fs.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ static int rx_create(struct mlx5_core_dev *mdev, struct mlx5e_ipsec *ipsec,
196196

197197
/* Create FT */
198198
ft = ipsec_ft_create(ns, MLX5E_ACCEL_FS_ESP_FT_LEVEL, MLX5E_NIC_PRIO,
199-
1);
199+
2);
200200
if (IS_ERR(ft)) {
201201
err = PTR_ERR(ft);
202202
goto err_fs_ft;
@@ -208,7 +208,7 @@ static int rx_create(struct mlx5_core_dev *mdev, struct mlx5e_ipsec *ipsec,
208208
goto err_fs;
209209

210210
ft = ipsec_ft_create(ns, MLX5E_ACCEL_FS_POL_FT_LEVEL, MLX5E_NIC_PRIO,
211-
1);
211+
2);
212212
if (IS_ERR(ft)) {
213213
err = PTR_ERR(ft);
214214
goto err_pol_ft;
@@ -307,13 +307,13 @@ static int tx_create(struct mlx5_core_dev *mdev, struct mlx5e_ipsec_tx *tx)
307307
struct mlx5_flow_table *ft;
308308
int err;
309309

310-
ft = ipsec_ft_create(tx->ns, 1, 0, 1);
310+
ft = ipsec_ft_create(tx->ns, 1, 0, 4);
311311
if (IS_ERR(ft))
312312
return PTR_ERR(ft);
313313

314314
tx->ft.sa = ft;
315315

316-
ft = ipsec_ft_create(tx->ns, 0, 0, 1);
316+
ft = ipsec_ft_create(tx->ns, 0, 0, 2);
317317
if (IS_ERR(ft)) {
318318
err = PTR_ERR(ft);
319319
goto err_pol_ft;

0 commit comments

Comments
 (0)