android_kernel_motorola_sm6225/drivers/infiniband/hw/ehca
Steve Wise 00f7ec36c9 RDMA/core: Add memory management extensions support
This patch adds support for the IB "base memory management extension"
(BMME) and the equivalent iWARP operations (which the iWARP verbs
mandates all devices must implement).  The new operations are:

 - Allocate an ib_mr for use in fast register work requests.

 - Allocate/free a physical buffer lists for use in fast register work
   requests.  This allows device drivers to allocate this memory as
   needed for use in posting send requests (eg via dma_alloc_coherent).

 - New send queue work requests:
   * send with remote invalidate
   * fast register memory region
   * local invalidate memory region
   * RDMA read with invalidate local memory region (iWARP only)

Consumer interface details:

 - A new device capability flag IB_DEVICE_MEM_MGT_EXTENSIONS is added
   to indicate device support for these features.

 - New send work request opcodes IB_WR_FAST_REG_MR, IB_WR_LOCAL_INV,
   IB_WR_RDMA_READ_WITH_INV are added.

 - A new consumer API function, ib_alloc_mr() is added to allocate
   fast register memory regions.

 - New consumer API functions, ib_alloc_fast_reg_page_list() and
   ib_free_fast_reg_page_list() are added to allocate and free
   device-specific memory for fast registration page lists.

 - A new consumer API function, ib_update_fast_reg_key(), is added to
   allow the key portion of the R_Key and L_Key of a fast registration
   MR to be updated.  Consumers call this if desired before posting
   a IB_WR_FAST_REG_MR work request.

Consumers can use this as follows:

 - MR is allocated with ib_alloc_mr().

 - Page list memory is allocated with ib_alloc_fast_reg_page_list().

 - MR R_Key/L_Key "key" field is updated with ib_update_fast_reg_key().

 - MR made VALID and bound to a specific page list via
   ib_post_send(IB_WR_FAST_REG_MR)

 - MR made INVALID via ib_post_send(IB_WR_LOCAL_INV),
   ib_post_send(IB_WR_RDMA_READ_WITH_INV) or an incoming send with
   invalidate operation.

 - MR is deallocated with ib_dereg_mr()

 - page lists dealloced via ib_free_fast_reg_page_list().

Applications can allocate a fast register MR once, and then can
repeatedly bind the MR to different physical block lists (PBLs) via
posting work requests to a send queue (SQ).  For each outstanding
MR-to-PBL binding in the SQ pipe, a fast_reg_page_list needs to be
allocated (the fast_reg_page_list is owned by the low-level driver
from the consumer posting a work request until the request completes).
Thus pipelining can be achieved while still allowing device-specific
page_list processing.

The 32-bit fast register memory key/STag is composed of a 24-bit index
and an 8-bit key.  The application can change the key each time it
fast registers thus allowing more control over the peer's use of the
key/STag (ie it can effectively be changed each time the rkey is
rebound to a page list).

Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
2008-07-14 23:48:45 -07:00
..
ehca_av.c IB/ehca: Remove tgid checking 2008-04-16 21:01:13 -07:00
ehca_classes.h IB/ehca: Wait for async events to finish before destroying QP 2008-05-07 11:35:06 -07:00
ehca_classes_pSeries.h IB/ehca: Fix warnings issued by checkpatch.pl 2007-07-17 18:37:40 -07:00
ehca_cq.c IB/ehca: Allocate event queue size depending on max number of CQs and QPs 2008-04-29 13:46:53 -07:00
ehca_eq.c IB/ehca: handle negative return value from ibmebus_request_irq() properly 2008-04-29 13:46:52 -07:00
ehca_hca.c IB/ehca: Fix function return types 2008-05-05 15:51:49 -07:00
ehca_irq.c IB/ehca: Wait for async events to finish before destroying QP 2008-05-07 11:35:06 -07:00
ehca_irq.h IB/ehca: Refactor sync between completions and destroy_cq using atomic_t 2007-07-09 20:12:27 -07:00
ehca_iverbs.h IB/ehca: Add PMA support 2008-02-04 20:20:42 -08:00
ehca_main.c IB/ehca: Allocate event queue size depending on max number of CQs and QPs 2008-04-29 13:46:53 -07:00
ehca_mcast.c IB/ehca: Print return codes as signed decimal integers 2007-10-09 19:59:10 -07:00
ehca_mrmw.c IB: expand ib_umem_get() prototype 2008-04-29 08:06:12 -07:00
ehca_mrmw.h IB/ehca: Support large page MRs 2007-07-20 21:19:43 -07:00
ehca_pd.c IB/ehca: Remove tgid checking 2008-04-16 21:01:13 -07:00
ehca_qes.h IB/ehca: Fix warnings issued by checkpatch.pl 2007-07-17 18:37:40 -07:00
ehca_qp.c IB/ehca: Wait for async events to finish before destroying QP 2008-05-07 11:35:06 -07:00
ehca_reqs.c RDMA/core: Add memory management extensions support 2008-07-14 23:48:45 -07:00
ehca_sqp.c IB/ehca: Add PMA support 2008-02-04 20:20:42 -08:00
ehca_tools.h IB: Replace remaining __FUNCTION__ occurrences with __func__ 2008-04-16 21:01:10 -07:00
ehca_uverbs.c IB/ehca: Move high-volume debug output to higher debug levels 2008-04-23 11:55:45 -07:00
hcp_if.c IB/ehca: Move high-volume debug output to higher debug levels 2008-04-23 11:55:45 -07:00
hcp_if.h IB/ehca: QP code restructuring in preparation for SRQ 2007-07-09 20:12:27 -07:00
hcp_phyp.c IB/ehca: Fix warnings issued by checkpatch.pl 2007-07-17 18:37:40 -07:00
hcp_phyp.h IB/ehca: Add driver for IBM eHCA InfiniBand adapters 2006-09-22 15:22:22 -07:00
hipz_fns.h IB/ehca: Add driver for IBM eHCA InfiniBand adapters 2006-09-22 15:22:22 -07:00
hipz_fns_core.h IB/ehca: Fix warnings issued by checkpatch.pl 2007-07-17 18:37:40 -07:00
hipz_hw.h IB/ehca: Serialize HCA-related hCalls if necessary 2007-12-12 14:09:43 -08:00
ipz_pt_fn.c IB/ehca: Small QP userspace support 2007-10-09 19:59:07 -07:00
ipz_pt_fn.h IB/ehca: Move extern declarations from .c files to .h files 2007-07-28 21:47:53 -07:00
Kconfig IB: Use menuconfig for InfiniBand menu 2007-07-09 20:12:26 -07:00
Makefile IB/ehca: Add driver for IBM eHCA InfiniBand adapters 2006-09-22 15:22:22 -07:00