]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
net/mlx5e: kTLS, Cleanup redundant capability check
authorTariq Toukan <tariqt@mellanox.com>
Mon, 22 Jun 2020 15:32:36 +0000 (18:32 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Sat, 27 Jun 2020 21:00:25 +0000 (14:00 -0700)
All callers of mlx5e_ktls_build_netdev() check capability
before the call.
Remove the repeated check in the function.

Signed-off-by: Tariq Toukan <tariqt@mellanox.com>
Reviewed-by: Maxim Mikityanskiy <maximmi@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ktls.c

index deec17af5a697338f0050818eec5ec1d86a8b6eb..1b392696280d227cca25d1fd32537ebad50c2cfc 100644 (file)
@@ -58,9 +58,6 @@ void mlx5e_ktls_build_netdev(struct mlx5e_priv *priv)
        struct net_device *netdev = priv->netdev;
        struct mlx5_core_dev *mdev = priv->mdev;
 
-       if (!mlx5_accel_is_ktls_device(mdev))
-               return;
-
        if (mlx5_accel_is_ktls_tx(mdev)) {
                netdev->hw_features |= NETIF_F_HW_TLS_TX;
                netdev->features    |= NETIF_F_HW_TLS_TX;