Skip to content

RDMA/mana_ib: Implement RNIC CQs

Konstantin Taranov linux-rdma lkml 2 versions – Applied

Status from this message: Applied, thanks!

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest5 patches 5 repliesApplied
  2. v16 patches 14 repliesSuperseded

Changes in v2 from the cover letter

1) removed patch that replace cqe with buf_size
2) added aditional check of queue id in the remove cb helper
3) removed buf_size from uapi request and added flags instead. It seems to be a better proposal that will not require to increase the ABI version.

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/5RDMA/mana_ib: create EQs for RNIC CQsdrivers/infiniband/hw/mana/main.c drivers/infiniband/hw/mana/mana_ib.h+33 -20 replies
2/5RDMA/mana_ib: create and destroy RNIC cqsdrivers/infiniband/hw/mana/main.c drivers/infiniband/hw/mana/mana_ib.h+86 -00 replies
3/5RDMA/mana_ib: introduce a helper to remove cq callbacksdrivers/infiniband/hw/mana/cq.c drivers/infiniband/hw/mana/mana_ib.h drivers/infiniband/hw/mana/qp.c+17 -290 replies
4/5RDMA/mana_ib: boundary check before installing cq callbacksdrivers/infiniband/hw/mana/cq.c+2 -00 replies
5/5RDMA/mana_ib: implement uapi for creation of rnic cqdrivers/infiniband/hw/mana/cq.c include/uapi/rdma/mana-abi.h+63 -44 replies

Reviews trailers per patch

All 5 patches have a Reviewed-by or Acked-by.

PatchLong Li
1/5R-b
2/5R-b
3/5R-b
4/5R-b
5/5R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH rdma-next v2 0/5] RDMA/mana_ib: Implement RNIC CQs

From: Konstantin Taranov <[email protected]>

This patch series implements creation and destruction of CQs which can be used with RC QPs.

Patches with RC QPs will be sent in the next patch series.

To create a CQ for RNIC, mana_ib requires creation of EQs within mana_ib device. An EQ of mana ethernet cannot be used.

To make the implementation of create_cq cleaner, this series also introduces a helper to remove CQ callbacks.

Mana ethernet and mana_ib CQs are different entities which are created in different isolation zones (ethernet vs rnic). As a result, RNIC cannot use ethenet CQs and ethernet cannot use RNIC CQs.
That is why, we use existing udata request for creation of ethernet CQs. If the request has an extra flag, then we create an RNIC CQ. The kernel-level CQs will be RNIC CQs (in future patches).

To preserve backward and forward compatibility with RDMA-CORE, we will make the following changes to mana provider in RDMA-CORE:

The rdma-core will request RNIC CQs by default, with the proposed request format and the special flag.
If the mana has installed an allocator with manadv_set_context_attr, then the rdma-core understands that this is a DPDK use-case and requests an ethernet CQ, by not setting the flag.

If the user has a new RDMA-core and an old kernel, then the user can detect it as the response to create RNIC cq will not have queue id.

If the user has an old RDMA-core, then the flags will be 0 and ethernet CQ will be created (as expected by the user).

v1->v2:
1) removed patch that replace cqe with buf_size
2) added aditional check of queue id in the remove cb helper
3) removed buf_size from uapi request and added flags instead. It seems to be a better proposal that will not require to increase the ABI version.

Konstantin Taranov (5):
RDMA/mana_ib: create EQs for RNIC CQs RDMA/mana_ib: create and destroy RNIC cqs RDMA/mana_ib: introduce a helper to remove cq callbacks RDMA/mana_ib: boundary check before installing cq callbacks RDMA/mana_ib: implement uapi for creation of rnic cq

 drivers/infiniband/hw/mana/cq.c      | 74 +++++++++++++++++++----
 drivers/infiniband/hw/mana/main.c    | 88 +++++++++++++++++++++++++++-
 drivers/infiniband/hw/mana/mana_ib.h | 34 +++++++++++
 drivers/infiniband/hw/mana/qp.c      | 26 ++------
 include/uapi/rdma/mana-abi.h         | 12 ++++
 5 files changed, 200 insertions(+), 34 deletions(-)
Signature · 1 line
2.43.0