Skip to content

Commit

Permalink
mlx5: Fix masking service level in mlx5_create_ah
Browse files Browse the repository at this point in the history
[ Upstream commit 3097859 ]

Fix masking of service level when creating AH to 4 bits in case of IB
link layer to match PRM definition.

Fixes: 4e0c234 ("mlx5: Fix SL to Ethernet priority conversion")
Signed-off-by: Michael Guralnik <[email protected]>
Signed-off-by: Yishai Hadas <[email protected]>
Signed-off-by: Nicolas Morey-Chaisemartin <[email protected]>
  • Loading branch information
mikijoy authored and nmorey committed Apr 24, 2019
1 parent 3d01f9b commit cfcd41c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion providers/mlx5/verbs.c
Original file line number Diff line number Diff line change
Expand Up @@ -1746,7 +1746,7 @@ struct ibv_ah *mlx5_create_ah(struct ibv_pd *pd, struct ibv_ah_attr *attr)
ah->av.fl_mlid = attr->src_path_bits & 0x7f;
ah->av.rlid = htobe16(attr->dlid);
grh = 1;
ah->av.stat_rate_sl = (static_rate << 4) | (attr->sl & 0x7);
ah->av.stat_rate_sl = (static_rate << 4) | (attr->sl & 0xf);
}
if (attr->is_global) {
ah->av.tclass = attr->grh.traffic_class;
Expand Down

0 comments on commit cfcd41c

Please sign in to comment.