mirror of
https://github.com/freebsd/freebsd-src
synced 2024-07-23 03:06:48 +00:00
ofed: mask seq_num identifier to occupy only 3 bytes
The seq_num among other things is used to assign rq_psn value, which is a 24-bit identifier. When the seq_num is full 4-byte value, we are usually receiving: '_ib_modify_qp rq_psn overflow, masking to 24 bits' warning. This is burdensome for running rdma traffic with large number of connections, because the number of logs is growing fast. Signed-off-by: Bartosz Sobczak <bartosz.sobczak@intel.com> Signed-off-by: Eric Joyner <erj@FreeBSD.org> Reviewed by: kib@, erj@ MFC after: 3 days Sponsored by: Intel Corporation Differential Revision: https://reviews.freebsd.org/D41531
This commit is contained in:
parent
80e9ea426c
commit
c7f73a1588
|
@ -787,6 +787,7 @@ struct rdma_cm_id *rdma_create_id(struct vnet *net,
|
|||
INIT_LIST_HEAD(&id_priv->listen_list);
|
||||
INIT_LIST_HEAD(&id_priv->mc_list);
|
||||
get_random_bytes(&id_priv->seq_num, sizeof id_priv->seq_num);
|
||||
id_priv->seq_num &= 0x00ffffff;
|
||||
id_priv->id.route.addr.dev_addr.net = net;
|
||||
|
||||
return &id_priv->id;
|
||||
|
|
Loading…
Reference in a new issue