Skip to content

Commit

Permalink
IB/mlx5: Fix decision on using MAD_IFC
Browse files Browse the repository at this point in the history
Fix the condition that dictates when MAD_IFC should be used. According
to firmware specifications, MAD_IFC commands must be used only if the
ib_virt capability is off.

Signed-off-by: Eli Cohen <[email protected]>
Reviewed-by: Or Gerlitz <[email protected]>
Signed-off-by: Doug Ledford <[email protected]>
  • Loading branch information
Eli Cohen authored and dledford committed Mar 21, 2016
1 parent cc8e27c commit d603c80
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/infiniband/hw/mlx5/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ __be16 mlx5_get_roce_udp_sport(struct mlx5_ib_dev *dev, u8 port_num,

static int mlx5_use_mad_ifc(struct mlx5_ib_dev *dev)
{
return !dev->mdev->issi;
return !MLX5_CAP_GEN(dev->mdev, ib_virt);
}

enum {
Expand Down

0 comments on commit d603c80

Please sign in to comment.