History log of /drivers/infiniband/hw/ipath/ipath_uc.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
9c3da0991754d480328eeaa2b90cb231a1cea9b6 18-Jan-2009 Harvey Harrison <harvey.harrison@gmail.com> IB: Remove __constant_{endian} uses

The base versions handle constant folding just fine, use them
directly. The replacements are OK in the include/ files as they are
not exported to userspace so we don't need the __ prefixed versions.

This patch does not affect code generation at all.

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
00f7ec36c9324928e4cd23f02e6d8550f30c32ca 15-Jul-2008 Steve Wise <swise@opengridcomputing.com> 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>
/drivers/infiniband/hw/ipath/ipath_uc.c
df3f0da8db6b5e7e8f0585221c8b1cd8ff806d35 16-May-2008 Ralph Campbell <ralph.campbell@qlogic.com> IB/ipath: Fix UC receive completion opcode for RDMA WRITE with immediate

When I fixed the RC receive completion opcode in 2bfc8e9e ("IB/ipath:
Return the correct opcode for RDMA WRITE with immediate"), I forgot to
fix UC, which had the same problem for RDMA write with immediate
returning the wrong opcode.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
e509be898d8937634437caa474b57ac12795e5bc 13-May-2008 Ralph Campbell <ralph.campbell@qlogic.com> IB/ipath: Fix many locking issues when switching to error state

The send DMA hardware queue voided a number of prior assumptions about
when a send is complete which led to completions being generated out of
order. There were also a number of locking issues when switching the QP
to the error or reset states, and we implement the IB_QPS_SQD state.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
0f39cf3d54e67a705773fd0ec56ca3dcd3e9272f 17-Apr-2008 Roland Dreier <rolandd@cisco.com> IB/core: Add support for "send with invalidate" work requests

Add a new IB_WR_SEND_WITH_INV send opcode that can be used to mark a
"send with invalidate" work request as defined in the iWARP verbs and
the InfiniBand base memory management extensions. Also put "imm_data"
and a new "invalidate_rkey" member in a new "ex" union in struct
ib_send_wr. The invalidate_rkey member can be used to pass in an
R_Key/STag to be invalidated. Add this new union to struct
ib_uverbs_send_wr. Add code to copy the invalidate_rkey field in
ib_uverbs_post_send().

Fix up low-level drivers to deal with the change to struct ib_send_wr,
and just remove the imm_data initialization from net/sunrpc/xprtrdma/,
since that code never does any send with immediate operations.

Also, move the existing IB_DEVICE_SEND_W_INV flag to a new bit, since
the iWARP drivers currently in the tree set the bit. The amso1100
driver at least will silently fail to honor the IB_SEND_INVALIDATE bit
if passed in as part of userspace send requests (since it does not
implement kernel bypass work request queueing). Remove the flag from
all existing drivers that set it until we know which ones are OK.

The values chosen for the new flag is not consecutive to avoid clashing
with flags defined in the XRC patches, which are not merged yet but
which are already in use and are likely to be merged soon.

This resurrects a patch sent long ago by Mikkel Hagen <mhagen@iol.unh.edu>.

Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
55046698faf6357ff7c53593dbfd43a9a3f681a7 17-Aug-2007 Ralph Campbell <ralph.campbell@qlogic.com> IB/ipath: UC RDMA WRITE with IMMEDIATE doesn't send the immediate

This patch fixes a bug in the receive processing for UC RDMA WRITE with
immediate which caused the last packet to be dropped.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
4ee97180ac76deb5a715ac45b7d7516e6ee82ae7 25-Jul-2007 Ralph Campbell <ralph.campbell@qlogic.com> IB/ipath: Change UD to queue work requests like RC & UC

The code to post UD sends tried to process work requests at the time
ib_post_send() is called without using a WQE queue. This was fine as
long as HW resources were available for sending a packet. This patch
changes UD to be handled more like RC and UC and shares more code.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
87427da55bc03dbce7906a5b09ed50279d654d28 11-Jun-2007 John Gregor <john.gregor@qlogic.com> IB/ipath: Update copyright dates

Now that it's June, it's about time to update
the copyright notices of files that have changed.

Signed-off-by: John Gregor <john.gregor@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
1dd6a1be1416be48cafda9e63a614f26f0428d10 18-Jun-2007 Ralph Campbell <ralph.campbell@qlogic.com> IB/ipath: Set M bit in BTH according to IB spec

According to chapter 17.2.8.1.1, QPs start in the migrated state and
should send packets with the M bit set in the BTH.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
2c9749c3b534ea0e606b7ee2c29849bbb8d5b0a9 18-Jun-2007 Ralph Campbell <ralph.campbell@qlogic.com> IB/ipath: Fix problem with next WQE after a UC completion

This patch fixes a bug introduced when moving some code around for
readability.

Setting the wqe pointer at the end of the function is a NOP since it
isn't used. Move it back to where it is used.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
3859e39d75b72f35f7d38c618fbbacb39a440c22 15-Mar-2007 Ralph Campbell <ralph.campbell@qlogic.com> IB/ipath: Support larger IB_QP_MAX_DEST_RD_ATOMIC and IB_QP_MAX_QP_RD_ATOMIC

This patch adds support for multiple RDMA reads and atomics to be sent
before an ACK is required to be seen by the requester.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
062dbb69f32b9ccea701b30f8cc0049482e6211f 31-Dec-2006 Michael S. Tsirkin <mst@mellanox.co.il> IB: Return qp pointer as part of ib_wc

struct ib_wc currently only includes the local QP number: this matches
the IB spec, but seems mostly useless. The following patch replaces
this with the pointer to qp itself, and updates all low level drivers
and all users.

This has the following advantages:
- Ability to get a per-qp context through wc->qp->qp_context
- Existing drivers already have the qp pointer ready in poll cq, so
this change actually saves a tiny bit (extra memory read) on data path
(for ehca it would actually be expensive to find the QP pointer when
polling a CQ, but ehca does not support SRQ so we can leave wc->qp as
NULL for ehca)
- Users that need the QP number can still get it through wc->qp->qp_num

Use case:

In IPoIB connected mode code, I have a common CQ shared by multiple
QPs. To track connection usage, I need a way to get at some per-QP
context upon the completion, and I would like to avoid allocating
context object per work request just to stick a QP pointer into it.
With this code, I can just use wc->qp->qp_context.

Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
6a553af286653818bb5831f1b351eefdc8a93b61 28-Sep-2006 Bryan O'Sullivan <bos@pathscale.com> IB/ipath: Ensure that PD of MR matches PD of QP checking the Rkey

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
10aeb0e6d8823c1cccf9edc8401c848745c128be 28-Sep-2006 Bryan O'Sullivan <bos@pathscale.com> IB/ipath: RC and UC should validate SLID and DLID

This is required for IB conformance (spec ch. 9.6.1.5).

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
34b2aafea38efdf02cd8107a6e1057e2a297c447 25-Aug-2006 Bryan O'Sullivan <bos@pathscale.com> IB/ipath: simplify layering code

A lot of ipath layer code was only called in one place. Now that the
ipath_core and ib_ipath drivers are merged, it's more sensible to simply
inline the simple stuff that the layer code was doing.

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c
27b678dd04a636f2c351816f4b3042c8815d4e9d 01-Jul-2006 Bryan O'Sullivan <bos@pathscale.com> [PATCH] IB/ipath: namespace cleanup: replace ips with ipath

Remove ips namespace from infinipath drivers. This renames ips_common.h to
ipath_common.h. Definitions, data structures, etc. that were not used by
kernel modules have moved to user-only headers. All names including ips have
been renamed to ipath. Some names have had an ipath prefix added.

Signed-off-by: Christian Bell <christian.bell@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Cc: "Michael S. Tsirkin" <mst@mellanox.co.il>
Cc: Roland Dreier <rolandd@cisco.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/drivers/infiniband/hw/ipath/ipath_uc.c
12eef41f8b72b6e11e36b48c78849c17e49781c8 01-Jul-2006 Bryan O'Sullivan <bos@pathscale.com> [PATCH] IB/ipath: rC receive interrupt performance changes

This patch separates QP state used for sending and receiving RC packets so the
processing in the receive interrupt handler can be done mostly without locks
being held. ACK packets are now sent without requiring synchronization with
the send tasklet.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Cc: "Michael S. Tsirkin" <mst@mellanox.co.il>
Cc: Roland Dreier <rolandd@cisco.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/drivers/infiniband/hw/ipath/ipath_uc.c
ddd4bb22108417fdc5c35324bd13a3265581ae76 01-Jul-2006 Bryan O'Sullivan <bos@pathscale.com> [PATCH] IB/ipath: share more common code between RC and UC protocols

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Cc: "Michael S. Tsirkin" <mst@mellanox.co.il>
Cc: Roland Dreier <rolandd@cisco.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/drivers/infiniband/hw/ipath/ipath_uc.c
759d57686dab8169ca68bbf938ce8e965d1e107a 01-Jul-2006 Bryan O'Sullivan <bos@pathscale.com> [PATCH] IB/ipath: update copyrights and other strings to reflect new company name

Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Cc: "Michael S. Tsirkin" <mst@mellanox.co.il>
Cc: Roland Dreier <rolandd@cisco.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/drivers/infiniband/hw/ipath/ipath_uc.c
74ed6b5eb133b4acae7c47bc23457e5f8e7c1125 30-Mar-2006 Bryan O'Sullivan <bos@pathscale.com> IB/ipath: infiniband UC and UD protocol support

These files implement the Infiniband UC ("unreliable connection") and UD
("unreliable datagram") protocols.

Signed-off-by: Bryan O'Sullivan <bos@pathscale.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/ipath/ipath_uc.c