]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5e: kTLS, Fix page refcnt leak in TX resync error flow
authorTariq Toukan <tariqt@mellanox.com>
Wed, 18 Sep 2019 10:57:40 +0000 (13:57 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Fri, 18 Oct 2019 19:11:52 +0000 (12:11 -0700)
commit2683246920fbb2ccec392c8f1beafd6d70724812
treea9fbc83c9f2cf9a15964b3310e03ca9bf09e564b
parenta25527d0657e38624e65c70708b49eee1c23c954
net/mlx5e: kTLS, Fix page refcnt leak in TX resync error flow

All references for frag pages that are obtained in tx_sync_info_get()
should be released.
Release usually occurs in the corresponding CQE of the WQE.
In error flows, not all fragments have a WQE posted for them, hence
no matching CQE will be generated.
For these pages, release the reference in the error flow.

Fixes: 3e985319cc11 ("net/mlx5e: Add kTLS TX HW offload support")
Signed-off-by: Tariq Toukan <tariqt@mellanox.com>
Reviewed-by: Eran Ben Elisha <eranbe@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ktls_tx.c