summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorJason Gunthorpe <jgg@mellanox.com>2020-01-12 19:46:19 -0400
committerJason Gunthorpe <jgg@mellanox.com>2020-01-12 19:48:54 -0400
commitaef5570e23dec7b0f7728687c04e7f888766c39e (patch)
tree5b2a2dad691293305b927ba1bf1ad2941bd29a8e /drivers
parent1e123d96b85fd41278efc994f8096e1df86fd427 (diff)
parentca1992c62cadb6c8e1e1b47e197b550f3cd89b76 (diff)
downloadlinux-aef5570e23dec7b0f7728687c04e7f888766c39e.tar.bz2
Merge branch 'mlx5_vdpa' into rdma.git for-next
From the mlx5-next branch at git://git.kernel.org/pub/scm/linux/kernel/git/mellanox/linux Merged due to dependencies in the next patches. * branch 'mlx5_vdpa': net/mlx5: Expose vDPA emulation device capabilities net/mlx5: Add Virtio Emulation related device capabilities
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/ethernet/mellanox/mlx5/core/fw.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/fw.c b/drivers/net/ethernet/mellanox/mlx5/core/fw.c
index a19790dee7b2..c375edfe528c 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/fw.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/fw.c
@@ -245,6 +245,13 @@ int mlx5_query_hca_caps(struct mlx5_core_dev *dev)
return err;
}
+ if (MLX5_CAP_GEN_64(dev, general_obj_types) &
+ MLX5_GENERAL_OBJ_TYPES_CAP_VIRTIO_NET_Q) {
+ err = mlx5_core_get_caps(dev, MLX5_CAP_VDPA_EMULATION);
+ if (err)
+ return err;
+ }
+
return 0;
}