net/mlx5_core: Fix caching ATOMIC endian mode capability

Add caching of maximum device capability of ATOMIC endian mode.

Fixes: f91e6d8941 ('net/mlx5_core: Add setting ATOMIC endian mode')
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Reviewed-by: Saeed Mahameed <saeedm@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
This commit is contained in:
Leon Romanovsky 2016-02-23 10:25:21 +02:00 committed by Doug Ledford
parent 5658600e7f
commit 91d9ed8443
1 changed files with 4 additions and 0 deletions

View File

@ -423,6 +423,10 @@ static int handle_hca_cap_atomic(struct mlx5_core_dev *dev)
HCA_CAP_OPMOD_GET_CUR);
if (err)
return err;
err = mlx5_core_get_caps(dev, MLX5_CAP_ATOMIC,
HCA_CAP_OPMOD_GET_MAX);
if (err)
return err;
} else {
return 0;
}