mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@ziepe.ca>
To: Joel Nider <joeln@il.ibm.com>
Cc: Jonathan Corbet <corbet@lwn.net>,
	Leon Romanovsky <leon@kernel.org>,
	Doug Ledford <dledford@redhat.com>,
	Mike Rapoport <rppt@linux.ibm.com>,
	linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 2/3] docs-rst: driver-api: Add infiniband interface documentation
Date: Fri, 1 Feb 2019 10:09:02 -0700	[thread overview]
Message-ID: <20190201170902.GB13002@ziepe.ca> (raw)
In-Reply-To: <1548151235-386-3-git-send-email-joeln@il.ibm.com>

On Tue, Jan 22, 2019 at 12:00:34PM +0200, Joel Nider wrote:
> A short document regarding the user verbs interface implementation on
> the kernel side. Also, the corresponding index entry in the
> documentation tree.
> 
> Signed-off-by: Joel Nider <joeln@il.ibm.com>
>  Documentation/driver-api/index.rst      |  1 +
>  Documentation/driver-api/infiniband.rst | 73 +++++++++++++++++++++++++++++++++
>  2 files changed, 74 insertions(+)
>  create mode 100644 Documentation/driver-api/infiniband.rst
> 
> diff --git a/Documentation/driver-api/index.rst b/Documentation/driver-api/index.rst
> index ab38ced..ecb3f8a5 100644
> +++ b/Documentation/driver-api/index.rst
> @@ -28,6 +28,7 @@ available subsections can be seen below.
>     regulator
>     iio/index
>     input
> +   infiniband
>     usb/index
>     firewire
>     pci/index
> diff --git a/Documentation/driver-api/infiniband.rst b/Documentation/driver-api/infiniband.rst
> new file mode 100644
> index 0000000..2de47ff
> +++ b/Documentation/driver-api/infiniband.rst
> @@ -0,0 +1,73 @@
> +==========================
> +Infiniband Interface Guide
> +==========================
> +
> +This guide is for people who wish to understand the implementation details of
> +handler functions in the Infiniband subsystem. There are currently two system
> +calls for executing Infiniband commands: write() and ioctl(). Older commands
> +are sent to the kernel via write()s on the device files described in
> +:doc:`../userspace-api/rdma_user_verbs`. New commands must use the ioctl()
> +method. For completeness, both mechanisms are described here.
> +
> +The interface between userspace and kernel is kept in sync by checking the
> +version number. In the kernel, it is defined by IB_USER_VERBS_ABI_VERSION
> +(in include/uapi/rdma/ib_user_verbs.h).
> +
> +Write system call
> +-----------------
> +The entry point to the kernel is the ib_uverbs_write() function, which is
> +invoked as a response to the 'write' system call. The requested function is
> +looked up from an array called uverbs_cmd_table which contains function pointers
> +to the various command handlers.

This array was deleted recently

> +Write Command Handlers
> +~~~~~~~~~~~~~~~~~~~~~~
> +These command handler functions are declared
> +with the IB_VERBS_DECLARE_CMD macro in drivers/infiniband/core/uverbs.h. There
> +are also extended commands, which are kept in a similar manner in the
> +uverbs_ex_cmd_table. The extended commands use 64-bit values in the command
> +header, as opposed to the 32-bit values used in the regular command table.

IB_VERBS_DELCARE_CMD is also deleted

> +Objects trees are declared using the DECLARE_UVERBS_OBJECT_TREE macro. This
> +combines all of the objects.

DECLARE_UVERBS_OBJECT_TREE as well

Jason

  reply	other threads:[~2019-02-01 17:09 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-22 10:00 [PATCH v3 0/3] update infiniband uverbs documentation Joel Nider
2019-01-22 10:00 ` [PATCH v3 1/3] docs-rst: Convert user verbs doc to rst Joel Nider
2019-01-22 10:00 ` [PATCH v3 2/3] docs-rst: driver-api: Add infiniband interface documentation Joel Nider
2019-02-01 17:09   ` Jason Gunthorpe [this message]
2019-01-22 10:00 ` [PATCH v3 3/3] MAINTAINERS: add new RDMA/Infiniband documentation Joel Nider
2019-01-30 12:57 ` [PATCH v3 0/3] update infiniband uverbs documentation Joel Nider
2019-01-30 19:24   ` Jonathan Corbet
2019-02-01 16:52 ` Jason Gunthorpe
2019-02-01 23:15   ` Jonathan Corbet
2019-02-03 12:54     ` Joel Nider

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=20190201170902.GB13002@ziepe.ca \
    --to=jgg@ziepe.ca \
    --cc=corbet@lwn.net \
    --cc=dledford@redhat.com \
    --cc=joeln@il.ibm.com \
    --cc=leon@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rppt@linux.ibm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®