linux-rdma.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Leon Romanovsky <leon@kernel.org>
To: Doug Ledford <dledford@redhat.com>, Jason Gunthorpe <jgg@mellanox.com>
Cc: Leon Romanovsky <leonro@mellanox.com>, linux-rdma@vger.kernel.org
Subject: [RFC PATCH rdma-core 00/11] Add Enhanced Connection Established (ECE) APIs
Date: Thu,  5 Mar 2020 17:03:45 +0200	[thread overview]
Message-ID: <20200305150356.208843-1-leon@kernel.org> (raw)

From: Leon Romanovsky <leonro@mellanox.com>

Hi,

This is user space part of previously sent kernel part. It is marked as RFC because
libmlx5 patch is not final and will be rewritten, however the concept is pretty solid.
I'm posting the series to the ML in attempt to gather feedback, and I already aware
of need to extend man pages to include definitions of struct ibv_ece.

Thanks

-------------------------------------------------------------------------------------
Enhanced Connection Established or ECE is new negotiation scheme
introduced in IBTA v1.4 to exchange extra information about nodes
capabilities and later negotiate them at the connection establishment
phase.

The RDMA-CM messages (REQ, REP, SIDR_REQ and SIDR_REP) were extended
to carry two fields, one new and another gained new functionality:
 * VendorID is a new field that indicates that common subset of vendor
   option bits are supported as indicated by that VendorID.
 * AttributeModifier already exists, but overloaded to indicate which
   vendor options are supported by this VendorID.

The general (success) communication flow can be described by the following table:

------------------------------------------------------------------------------
Requester (client)                        | Responder (server)
-----------------------------------------------------------------------------
1. Create data QP.                        |
2. Get ECE information about this QP.     |
3. Update REQ message with local ECE data.|
4. Send REQ message with rdma_connect().  |
                                          | 5. Get REQ message with rdma_get_events.
                                          | 6. Read remote ECE data from the REQ message.
                                          | 7. Create data QP.
                                          | 8. Set in QP the desired ECE options by giving remote ECE data.
                                          | 9. Read accepted local ECE options.
                                          |10. Modify QP based on those options.
                                          |11. Fill local ECE options in REP message.
                                          |12. Send REP message with rdma_accept().
13. Receive REP message.                  |
14. Read remote ECE data from REP message.|
15. Set in QP remote ECE data             |
16. Modify QP based on remote ECE data    |
------------------------------------------------------------------------------

In case the server decides to reject connection, the items #9-10 will be
replaced with rdma_reject_ece() call that will send REJ message together
with "ECE options not supported" reason as described in the IBTA.

Thanks

Leon Romanovsky (11):
  Update kernel headers
  libibverbs: Add interfaces to configure and use ECE
  mlx5: Implement ECE callbacks
  libibverbs: Document ECE API
  debian: Install all available librdmacm man pages
  librdmacm: Provide interface to use ECE for external QPs
  librdmacm: Connect rdma_connect to the ECE
  librdmacm: Return ECE results through rdma_accept
  librdmacm: Add an option to reject ECE request
  librdmacm: Implement ECE handshake logic
  librdmacm: Document ECE API

 CMakeLists.txt                         |   2 +-
 debian/libibverbs1.symbols             |   5 +-
 debian/librdmacm-dev.install           |  53 +---------
 debian/librdmacm1.symbols              |   4 +
 kernel-headers/rdma/rdma_user_cm.h     |  15 ++-
 libibverbs/CMakeLists.txt              |   2 +-
 libibverbs/driver.h                    |   2 +
 libibverbs/dummy_ops.c                 |  14 +++
 libibverbs/libibverbs.map.in           |   6 ++
 libibverbs/man/CMakeLists.txt          |   2 +
 libibverbs/man/ibv_query_ece.3.md      |  56 +++++++++++
 libibverbs/man/ibv_set_ece.3.md        |  61 ++++++++++++
 libibverbs/verbs.c                     |  15 +++
 libibverbs/verbs.h                     |  18 ++++
 librdmacm/CMakeLists.txt               |   2 +-
 librdmacm/cma.c                        | 130 +++++++++++++++++++++++--
 librdmacm/librdmacm.map                |   7 ++
 librdmacm/man/CMakeLists.txt           |   2 +
 librdmacm/man/rdma_cm.7                |  14 ++-
 librdmacm/man/rdma_get_remote_ece.3.md |  61 ++++++++++++
 librdmacm/man/rdma_set_local_ece.3.md  |  62 ++++++++++++
 librdmacm/rdma_cma.h                   |  24 +++++
 librdmacm/rdma_cma_abi.h               |  15 ++-
 providers/mlx5/mlx5.c                  |   6 +-
 providers/mlx5/mlx5.h                  |  10 ++
 providers/mlx5/qp.c                    |  33 +++++++
 providers/mlx5/verbs.c                 |   9 ++
 27 files changed, 560 insertions(+), 70 deletions(-)
 create mode 100644 libibverbs/man/ibv_query_ece.3.md
 create mode 100644 libibverbs/man/ibv_set_ece.3.md
 create mode 100644 librdmacm/man/rdma_get_remote_ece.3.md
 create mode 100644 librdmacm/man/rdma_set_local_ece.3.md

--
2.24.1


             reply	other threads:[~2020-03-05 15:04 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-05 15:03 Leon Romanovsky [this message]
2020-03-05 15:03 ` [RFC PATCH rdma-core 01/11] Update kernel headers Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 02/11] libibverbs: Add interfaces to configure and use ECE Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 03/11] mlx5: Implement ECE callbacks Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 04/11] libibverbs: Document ECE API Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 05/11] debian: Install all available librdmacm man pages Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 06/11] librdmacm: Provide interface to use ECE for external QPs Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 07/11] librdmacm: Connect rdma_connect to the ECE Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 08/11] librdmacm: Return ECE results through rdma_accept Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 09/11] librdmacm: Add an option to reject ECE request Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 10/11] librdmacm: Implement ECE handshake logic Leon Romanovsky
2020-03-05 15:03 ` [RFC PATCH rdma-core 11/11] librdmacm: Document ECE API Leon Romanovsky

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=20200305150356.208843-1-leon@kernel.org \
    --to=leon@kernel.org \
    --cc=dledford@redhat.com \
    --cc=jgg@mellanox.com \
    --cc=leonro@mellanox.com \
    --cc=linux-rdma@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).