Date: Mon, 26 Jul 2021 15:19:41 GMT From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: 976a59ba6da5 - stable/13 - mlx5en: Add missing error case when creating VXLAN flow tables. Message-ID: <202107261519.16QFJfkG025710@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=976a59ba6da59a9bebd609f792e23303de5df903 commit 976a59ba6da59a9bebd609f792e23303de5df903 Author: Hans Petter Selasky <hselasky@FreeBSD.org> AuthorDate: 2021-06-16 13:01:27 +0000 Commit: Konstantin Belousov <kib@FreeBSD.org> CommitDate: 2021-07-26 13:51:11 +0000 mlx5en: Add missing error case when creating VXLAN flow tables. (cherry picked from commit 2f7ce2326f9486e90cda2f0129331e1ab3694252) --- sys/dev/mlx5/mlx5_en/mlx5_en_flow_table.c | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/sys/dev/mlx5/mlx5_en/mlx5_en_flow_table.c b/sys/dev/mlx5/mlx5_en/mlx5_en_flow_table.c index 6be95550c713..cdfe19d910d1 100644 --- a/sys/dev/mlx5/mlx5_en/mlx5_en_flow_table.c +++ b/sys/dev/mlx5/mlx5_en/mlx5_en_flow_table.c @@ -2252,34 +2252,28 @@ mlx5e_open_flow_table(struct mlx5e_priv *priv) err = mlx5e_create_main_flow_table(priv, true); if (err) goto err_destroy_main_flow_table; - } - if ((priv->ifp->if_capenable & IFCAP_VXLAN_HWCSUM) != 0) { err = mlx5e_create_inner_rss_flow_table(priv); if (err) goto err_destroy_main_vxlan_flow_table; - } - if ((priv->ifp->if_capenable & IFCAP_VXLAN_HWCSUM) != 0) { err = mlx5e_add_vxlan_catchall_rule(priv); if (err != 0) goto err_destroy_inner_rss_flow_table; - } - if ((priv->ifp->if_capenable & IFCAP_VXLAN_HWCSUM) != 0) { err = mlx5e_add_main_vxlan_rules(priv); if (err != 0) - goto err_destroy_inner_rss_flow_table; + goto err_destroy_vxlan_catchall_rule; } return (0); +err_destroy_vxlan_catchall_rule: + mlx5e_del_vxlan_catchall_rule(priv); err_destroy_inner_rss_flow_table: - if ((priv->ifp->if_capenable & IFCAP_VXLAN_HWCSUM) != 0) - mlx5e_destroy_inner_rss_flow_table(priv); + mlx5e_destroy_inner_rss_flow_table(priv); err_destroy_main_vxlan_flow_table: - if ((priv->ifp->if_capenable & IFCAP_VXLAN_HWCSUM) != 0) - mlx5e_destroy_main_vxlan_flow_table(priv); + mlx5e_destroy_main_vxlan_flow_table(priv); err_destroy_main_flow_table: mlx5e_destroy_main_flow_table(priv); err_destroy_vxlan_flow_table:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202107261519.16QFJfkG025710>