From: "Saleem, Shiraz" <shiraz.saleem@intel.com>
To: "yanjun.zhu@linux.dev" <yanjun.zhu@linux.dev>,
"liangwenpeng@huawei.com" <liangwenpeng@huawei.com>,
"liweihang@huawei.com" <liweihang@huawei.com>,
"jgg@ziepe.ca" <jgg@ziepe.ca>,
"Ismail, Mustafa" <mustafa.ismail@intel.com>,
"zyjzyj2000@gmail.com" <zyjzyj2000@gmail.com>,
"linux-rdma@vger.kernel.org" <linux-rdma@vger.kernel.org>
Subject: RE: [PATCH 3/4] RDMA/irdma: Make the source udp port vary
Date: Tue, 4 Jan 2022 17:18:01 +0000 [thread overview]
Message-ID: <1f6f5d2c6c3c422caa69d65e89f30d99@intel.com> (raw)
In-Reply-To: <20220105080727.2143737-4-yanjun.zhu@linux.dev>
> Subject: [PATCH 3/4] RDMA/irdma: Make the source udp port vary
>
> From: Zhu Yanjun <yanjun.zhu@linux.dev>
>
> Get the source udp port number for a QP based on the grh.flow_label or
> lqpn/rqrpn. This provides a better spread of traffic across NIC RX queues.
>
> Signed-off-by: Zhu Yanjun <yanjun.zhu@linux.dev>
> ---
> drivers/infiniband/hw/irdma/verbs.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/infiniband/hw/irdma/verbs.c b/drivers/infiniband/hw/irdma/verbs.c
> index 8cd5f9261692..09dba7ed5ab9 100644
> --- a/drivers/infiniband/hw/irdma/verbs.c
> +++ b/drivers/infiniband/hw/irdma/verbs.c
> @@ -1167,6 +1167,11 @@ int irdma_modify_qp_roce(struct ib_qp *ibqp, struct
> ib_qp_attr *attr,
>
> memset(&iwqp->roce_ah, 0, sizeof(iwqp->roce_ah));
> if (attr->ah_attr.ah_flags & IB_AH_GRH) {
> + u32 fl = attr->ah_attr.grh.flow_label;
> + u32 lqp = ibqp->qp_num;
> + u32 rqp = roce_info->dest_qp;
> +
> +
Do you really need these locals?
udp_info->src_port = rdma_get_udp_sport(fl, lqp, rqp);
> udp_info->ttl = attr->ah_attr.grh.hop_limit;
> udp_info->flow_label = attr->ah_attr.grh.flow_label;
> udp_info->tos = attr->ah_attr.grh.traffic_class;
> --
> 2.27.0
next prev parent reply other threads:[~2022-01-04 17:18 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-05 8:07 [PATCH 0/4] Generate UDP src port with flow label or lqpn/rqpn yanjun.zhu
2022-01-05 8:07 ` [PATCH 1/4] RDMA/core: Calculate UDP source port based on " yanjun.zhu
2022-01-05 13:51 ` Mark Zhang
2022-01-05 14:11 ` Yanjun Zhu
2022-01-05 8:07 ` [PATCH 2/4] RDMA/hns: Replace get_udp_sport with rdma_get_udp_sport yanjun.zhu
2022-01-05 8:07 ` [PATCH 3/4] RDMA/irdma: Make the source udp port vary yanjun.zhu
2022-01-04 17:18 ` Saleem, Shiraz [this message]
2022-01-04 19:26 ` Leon Romanovsky
2022-01-05 0:41 ` Yanjun Zhu
2022-01-05 8:07 ` [PATCH 4/4] RDMA/rxe: Use the standard method to produce udp source port yanjun.zhu
2022-01-04 17:17 ` Saleem, Shiraz
2022-01-05 0:33 ` Yanjun Zhu
2022-01-05 13:10 ` Yanjun Zhu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1f6f5d2c6c3c422caa69d65e89f30d99@intel.com \
--to=shiraz.saleem@intel.com \
--cc=jgg@ziepe.ca \
--cc=liangwenpeng@huawei.com \
--cc=linux-rdma@vger.kernel.org \
--cc=liweihang@huawei.com \
--cc=mustafa.ismail@intel.com \
--cc=yanjun.zhu@linux.dev \
--cc=zyjzyj2000@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.