summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/mellanox/mlx5
diff options
context:
space:
mode:
authorTariq Toukan <tariqt@mellanox.com>2019-07-21 14:13:15 +0300
committerSaeed Mahameed <saeedm@mellanox.com>2019-08-08 23:01:19 +0300
commit55c9bd37ef5a0bd79c80c8eb418ce162bbc65590 (patch)
treeed13a64ffb94b02b10eddaf15ff0ec6ee84dd1db /drivers/net/ethernet/mellanox/mlx5
parent5faf5b70c51dd9c9905bf8209e33cbd867486607 (diff)
downloadlinux-55c9bd37ef5a0bd79c80c8eb418ce162bbc65590.tar.xz
net/mlx5: crypto, Fix wrong offset in encryption key command
Fix the 128b key offset in key encryption key creation command, per the HW specification. Fixes: 45d3b55dc665 ("net/mlx5: Add crypto library to support create/destroy encryption key") Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlx5')
-rw-r--r--drivers/net/ethernet/mellanox/mlx5/core/lib/crypto.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/lib/crypto.c b/drivers/net/ethernet/mellanox/mlx5/core/lib/crypto.c
index ea9ee88491e5..ea1d4d26ece0 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/lib/crypto.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/lib/crypto.c
@@ -27,6 +27,7 @@ int mlx5_create_encryption_key(struct mlx5_core_dev *mdev,
case 128:
general_obj_key_size =
MLX5_GENERAL_OBJECT_TYPE_ENCRYPTION_KEY_KEY_SIZE_128;
+ key_p += sz_bytes;
break;
case 256:
general_obj_key_size =