<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<html>
<head>
<link rel="stylesheet" href="./robodoc.css" type="text/css">
<title>./iba_doc/ib_ci_h.html</title>
<!-- Source: ./iba/ib_ci.h -->
<!-- Generated with ROBODoc Version 4.99.17 (Aug 2 2005) -->
</head>
<body bgcolor="#FFFFFF">
<a name="robo_top_of_doc">Generated from ./iba/ib_ci.h</a> with <a href="http://sourceforge.net/projects/robodoc/">ROBODoc</a> v4.99.17 on Thu Sep 22 2005 14:46:33
<br />
<hr />
<h2><a name="robo1">[Modules]<a name="IB5fAPI2fVerbs">
IB_API/Verbs</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="./robo_modules.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>Verbs</strong> -- <strong>Verbs</strong> implements the hardware and software glue to the OS layer.
</pre>
</span><p><strong>COPYRIGHT</strong></p>
<span class="COPYRIGHT"><pre> Copyright© 2001 Intel Corporation - All Rights Reserved.
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> The <strong>Verbs</strong> API definition defines the interface mechanism between an IHV
supplied driver component. It implements verbs functionality as defined
Volume 1, of the InfiniBand(tm) specifications.
</pre>
</span><p><strong>AUTHOR</strong></p>
<span class="AUTHOR"><pre> Intel Corporation
</pre>
</span><p><strong>CREATION DATE</strong></p>
<span class="CREATION_DATE"><pre> XX.XX.XX
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> Evolving Spec!!
Invalid Handle checks are a mere signature checks in kernel mode. Hence
passing invalid pointer would lead to panics in the kernel. For user mode
These are verified for most verbs that need to take a kernel transition.
<strong>Verbs</strong> those are entirely done in user mode that would affect speed path
do not perform consistency checks. So invalid pointers would lead to
application crash with core dumps.
</pre>
</span>
<hr />
<h2><a name="robo564">[Functions]<a name="Verbs2fci5fallocate5fpd">
Verbs/ci_allocate_pd</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_allocate_pd</strong> -- Allocate a protection domain for this adapter.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_allocate_pd</strong>) (
IN const ib_ca_handle_t h_ca,
IN const <a href="./ib_types_h.html#robo125">ib_pd_type_t</a> type,
OUT ib_pd_handle_t *ph_pd,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine allocates a protection domain handle, which is later
used to create QP's, Register Memory Regions, Bind Memory Windows
and address vectors. Protection domain has no InfiniBand architectural
attributes but the OS implements policy on its usage and allocation.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_ca
[in] Handle returned by <a href="#robo591">ci_open_ca</a>()
type
[in] Type of the protection domain. CA vendors may use this
information to optimize how the PD is allocated.
ph_pd
[out] The handle to the newly created protection domain
p_umv_buf
[in/out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
PD is successfully allocated and the ph_pd is valid.
IB_INSUFFICIENT_RESOURCES
No more PD's available for this adapter.
IB_INVALID_CA_HANDLE
HCA handle is not valid
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo575">ci_deallocate_pd</a>
</pre>
</span>
<hr />
<h2><a name="robo565">[Functions]<a name="Verbs2fci5fasync5fevent5fcb5ft">
Verbs/ci_async_event_cb_t</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_async_event_cb_t</strong>
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> Asynchronous event notification routine.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef void
(*<strong>ci_async_event_cb_t</strong>)(
IN const <a href="./ib_types_h.html#robo612">ib_event_rec_t</a>* const p_event_record );
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> p_event_record
[in] Information describing the type of event that has occurred.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> This routine is called when an asynchronous event is generated by a
channel adapter. The event notification record passed has relevant
information on the type of the event, the source that caused the event,
and the context associated.
</pre>
</span>
<hr />
<h2><a name="robo566">[Functions]<a name="Verbs2fci5fattach5fmcast">
Verbs/ci_attach_mcast</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_attach_mcast</strong> -- Attach a queue pair to a multicast group
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_attach_mcast</strong>) (
IN const ib_qp_handle_t h_qp,
IN const <a href="./ib_types_h.html#robo370">ib_gid_t</a> *p_mcast_gid,
IN const <a href="./ib_types_h.html#robo407">ib_net16_t</a> mcast_lid,
OUT ib_mcast_handle_t *ph_mcast,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine attaches the given qp_handle to a multicast gid as specified
by mcast_gid parameter.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_qp
[in] Queue pair handle which needs to be added to the multicast group
on the adapter.
mcast_lid
[in] The multicast group LID value.
p_mcast_gid
[in] IPv6 address associated with this multicast group.
ph_mcast
[out] Multicast handle holding the association of this queue pair
to the multicast group.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The queue pair handle was successfully added to the multicast
group.
IB_INVALID_QP_HANDLE
qp_handle supplied is invalid.
IB_INVALID_SERVICE_TYPE
Queue pair handle supplied is not of unreliable datagram type.
IB_INVALID_GID
The supplied addr is not a valid multicast ipv6 address.
IB_INVALID_LID
The supplied lid is not a valid multicast lid.
IB_UNSUPPORTED
Multicast is not supported by this HCA.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to complete request.
IB_INVALID_PARAMETER
One of the parameters was NULL.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo573">ci_create_qp</a>, <a href="#robo581">ci_detach_mcast</a>
</pre>
</span>
<hr />
<h2><a name="robo567">[Functions]<a name="Verbs2fci5fbind5fmw">
Verbs/ci_bind_mw</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_bind_mw</strong> -- Bind a memory window to a memory region.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_bind_mw</strong>) (
IN const ib_mw_handle_t h_mw,
IN const ib_qp_handle_t h_qp,
IN <a href="./ib_types_h.html#robo19">ib_bind_wr_t</a>* const p_mw_bind,
OUT net32_t* const p_rkey );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine posts a request to bind a memory window to a registered
memory region. If the queue pair was created with selectable signaling,
once the operation is completed successfully then a completion queue entry
is generated indicating the bind operation has completed. The IB_POST_FENCE
option could be specified to cause the requestor to wait until outstanding
RDMA operations can be completed.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_mw
[in] Handle to memory window that needs to be bound to a memory region.
h_qp
[in] Queue Pair to which this bind request is to be posted.
p_mw_bind
[in] Input parameters for this bind request, consisting of virtual
addr range of bind request etc.
p_rkey
[out] On successful completion, the new R_KEY is returned.
VPD is required to give this in the expected ordering on the wire. When
rkey's are exchanged between remote nodes, no swapping of this data
will be performed.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The memory bind operation was posted successfully.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to complete the request.
No more WQE's to post this request
No more free WQE's to post this request
IB_INVALID_MW_HANDLE
memw_handle supplied is an invalid memory window handle.
IB_INVALID_PERMISSION
Invalid access rights specified in request
IB_INVALID_SERVICE_TYPE
Invalid service type for this qp_handle.
IB_INVALID_PARAMETER
One of the pointers was not valid.
IB_INVALID_RKEY
R_KEY specified is invalid for the memory region being bound.
IB_INVALID_QP_HANDLE
h_qp supplied was an invalid QP handle.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> - A previously bound memory window can be bound to the same or different
memory region.
- A bind operation with length of 0, invalidates any previous binding
and returns an R_KEY in the unbound state.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo572">ci_create_mw</a>
</pre>
</span>
<hr />
<h2><a name="robo568">[Functions]<a name="Verbs2fci5fclose5fca">
Verbs/ci_close_ca</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_close_ca</strong> -- Close access to adapter via this h_ca
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_close_ca</strong>) (
IN ib_ca_handle_t h_ca );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine is called when the client no longer wishes to use HCA
resources obtained via this h_ca. All resources allocated as part
this handle during the <a href="#robo591">ci_open_ca</a> are destroyed.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_ca
[in] CA handle returned via the <a href="#robo591">ci_open_ca</a>() call.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The intend to destroy is registered. No further calls for
completion or async event will be sent to this instance. When it is
appropriate to destroy this instance, the event h_kevent is signaled.
IB_RESOURCE_BUSY
Some resource allocated via this handle is not freed.
IB_INVALID_CA_HANDLE
h_ca is invalid
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> This call cannot be called from any of the notification functions invoked
by the <a href="#robo1">Verbs</a> driver. For e.g. the completion handler or the async error
callback provided during the <a href="#robo591">ci_open_ca</a>() call. The call will block until
all references to this adapter object is closed which includes all the
pending callbacks returning back to the verbs provider driver.
Resources allocated during the <a href="#robo591">ci_open_ca</a>() is deallocated. Other resource
cleanup are responsibility of the consumer .
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo591">ci_open_ca</a>
</pre>
</span>
<hr />
<h2><a name="robo569">[Functions]<a name="Verbs2fci5fcompletion5fcb5ft">
Verbs/ci_completion_cb_t</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_completion_cb_t</strong> -- Completion Notification callback.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef void
(*<strong>ci_completion_cb_t</strong>)(
IN void *cq_context );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This function prototype indicates the parameter passed to <a href="#robo591">ci_open_ca</a>()
to receive completion callbacks.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> cq_context
[in] Completion queue context passed during the <a href="#robo571">ci_create_cq</a>
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> None
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> The consumer only gets the cq_context and ca_context. It is the client
responsibility to store the cq_handle in the context after the creation
time. So it can call <a href="#robo593">ci_poll_cq</a>() after the arrival of the notification.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo591">ci_open_ca</a>, <a href="#robo571">ci_create_cq</a>
</pre>
</span>
<hr />
<h2><a name="robo570">[Functions]<a name="Verbs2fci5fcreate5fav">
Verbs/ci_create_av</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_create_av</strong> -- Create an address vector for use in UD.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_create_av</strong>) (
IN const ib_pd_handle_t h_pd,
IN const <a href="./ib_types_h.html#robo17">ib_av_attr_t</a> *p_av_attr,
OUT ib_av_handle_t *ph_av,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine creates an address vector for use in unreliable datagram
queue pairs. The information necessary to create the address vector
handle is supplied in the <a href="./ib_types_h.html#robo17">ib_av_attr_t</a> parameter.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_pd
[in] Protection domain to which this av is associated.
p_av_attr
[in] Parameters to create the address vector handle
ph_av
[out] Handle to use for datagram sends.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The create operation was successful
IB_INSUFFICIENT_RESOURCES
No more address handles are available
IB_INVALID_PD_HANDLE
The specified protection domain handle is invalid
IB_INVALID_PORT
Invalid port number supplied.
IB_INVALID_PARAMETER
One of the p_av_attr or p_av_attr was NULL.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> The values in the p_av_attr is not validated for correctness. The values
in the attribute such as port number, protection domain etc are also
validated during processing by the channel adapter. If the attribute
validation fails a processing error IB_WCS_LOCAL_OP_ERR.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo564">ci_allocate_pd</a>
</pre>
</span>
<hr />
<h2><a name="robo571">[Functions]<a name="Verbs2fci5fcreate5fcq">
Verbs/ci_create_cq</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_create_cq</strong> -- Create a completion queue (CQ) on the specified HCA.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_create_cq</strong>) (
IN const ib_ca_handle_t h_ca,
IN const void *cq_context,
IN OUT uint32_t* const p_size,
OUT ib_cq_handle_t *ph_cq,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> The consumer must specify the minimum number of entries in the CQ. The
exact number of entries the Channel Interface created is returned to the
client. If the requested number of entries is larger than what this
HCA can support, an error is returned.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_ca
[in] A handle to the open HCA
cq_context
[in] The context that is passed during the completion callbacks.
p_size
[in out] Points to a variable containing the number of CQ entries
requested by the consumer. On completion points to the size of the
CQ that was created by the provider.
ph_cq
[out] Handle to the newly created CQ on successful creation.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The operation was successful.
IB_INVALID_CA_HANDLE
The h_ca passed is invalid.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to complete request.
IB_INVALID_CQ_SIZE
Requested CQ Size is not supported.
IB_INVALID_PARAMETER
one of the parameters was NULL.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> The consumer would need a way to retrieve the cq_handle associated with
context being returned, so it can perform <a href="#robo593">ci_poll_cq</a>() to retrieve
completion queue entries. The handle as such is not being passed, since
there is no information in the handle that is visible to the consumer.
Passing a context directly would help avoid any reverse lookup that the
consumer would need to perform in order to identify it's own internal
data-structures needed to process this completion completely.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo578">ci_destroy_cq</a>, <a href="#robo598">ci_query_cq</a>, <a href="#robo605">ci_resize_cq</a>
</pre>
</span>
<hr />
<h2><a name="robo572">[Functions]<a name="Verbs2fci5fcreate5fmw">
Verbs/ci_create_mw</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_create_mw</strong> -- Create a memory window entry for later use
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_create_mw</strong>) (
IN const ib_pd_handle_t h_pd,
OUT net32_t* const p_rkey,
OUT ib_mw_handle_t *ph_mw,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine allocates a memory window. This window entry cannot be used
for remote access unless this window is bound to a memory region
via the <a href="#robo567">ci_bind_mw</a> call.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_pd
[in] Protection domain handle to use for this memory window
p_rkey
[out] Remote access key that can be exchanged with a remote node to
perform RDMA transactions on this memory window. This R_KEY is still not
bound to any memory regions, until a successful call to <a href="#robo567">ci_bind_mw</a>.
VPD is required to give this in the expected ordering on the wire. When
rkey's are exchanged between remote nodes, no swapping of this data
will be performed.
ph_mw
[out] Handle to the newly created memory window.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The memory window allocation completed successfully.
IB_INSUFFICIENT_RESOURCES
Not enough resources to complete the request.
IB_INVALID_PD_HANDLE
pd_handle supplied is invalid.
IB_INVALID_PARAMETER
One of the pointers was not valid.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo579">ci_destroy_mw</a>, <a href="#robo600">ci_query_mw</a>, <a href="#robo567">ci_bind_mw</a>
</pre>
</span>
<hr />
<h2><a name="robo573">[Functions]<a name="Verbs2fci5fcreate5fqp">
Verbs/ci_create_qp</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_create_qp</strong> -- Create a Queue Pair for the specified HCA
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_create_qp</strong>) (
IN const ib_pd_handle_t h_pd,
IN const void *qp_context,
IN const <a href="./ib_types_h.html#robo166">ib_qp_create_t</a> *p_create_attr,
OUT <a href="./ib_types_h.html#robo165">ib_qp_attr_t</a> *p_qp_attr,
OUT ib_qp_handle_t *ph_qp,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> A new queue pair is created on the specified HCA. The initial set of
parameters is provided by the qp_create_attr parameter. The newly created
queue pair, with its attributes such as the qp number is returned
in the qp_query_attr structure.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_pd
[in] Handle to Protection Domain
qp_context
[in] A user specified context passed in a asynchronous error callback.
p_create_attr
[in] Initial attributes with which the qp must be created.
p_qp_attr
[out] Attributes of the newly created queue pair.
ph_qp
[out] Handle to the queue pair newly created.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The queue pair is successfully created with the provided initial
attributes.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to complete request.
IB_INVALID_PD_HANDLE
pd_handle supplied in the qp_create_attr is invalid
IB_INVALID_CQ_HANDLE
cq_handle supplied for send/receive is invalid.
IB_INVALID_SERVICE_TYPE
Invalid service type.
IB_INVALID_MAX_WRS
Max WRS capacity exceeded
IB_INVALID_MAX_SGE
Max Scatter gather element request exceeds HCA capability
IB_UNSUPPORTED
Unreliable datagram not supported
IB_INVALID_PARAMETER
The parameter p_create_attr is invalid.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> If any of the initial parameters is not valid, the queue pair is not
created. If the routine call is not successful then the contents of
qp_query_attr and qp_handle is undefined.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo574">ci_create_spl_qp</a>, <a href="#robo601">ci_query_qp</a>, <a href="#robo590">ci_modify_qp</a>, <a href="#robo580">ci_destroy_qp</a>
</pre>
</span>
<hr />
<h2><a name="robo574">[Functions]<a name="Verbs2fci5fcreate5fspl5fqp">
Verbs/ci_create_spl_qp</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_create_spl_qp</strong> -- Create a special queue pair.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_create_spl_qp</strong>) (
IN const ib_pd_handle_t h_pd,
IN const uint8_t port_num,
IN const void *qp_context,
IN const <a href="./ib_types_h.html#robo166">ib_qp_create_t</a> *p_create_attr,
OUT <a href="./ib_types_h.html#robo165">ib_qp_attr_t</a> *p_qp_attr,
OUT ib_qp_handle_t *ph_qp );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> Create and return a handle to for the indicated service type on the
specified port. QP service types can be one of SMI, GSI, Raw IPv6 or
Raw ether type as specified in qp_type_t.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_pd
[in] Handle to the PD on which the special queue pair is to be created.
port_num
[in] Port number for which this special queue pair is created.
qp_context
[in] User specified context passed during the async error callback
routine.
p_create_attr
[in] Initial set of attributes with which the queue pair is to be
created.
p_qp_attr
[out] QP attributes after the qp is successfully created.
ph_qp
[out] Handle to the special qp after its creation.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The special queue pair of the requested service type is created.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to satisfy the request.
IB_NOT_FOUND
Indicated port guid is not found on this HCA.
IB_INVALID_CQ_HANDLE
Invalid cq handle passed to send/receive side.
IB_INVALID_MAX_WRS
Max WRS capacity exceeded
IB_INVALID_MAX_SGE
Max Scatter gather element request exceeds HCA capability
IB_RESOURCE_BUSY
Applicable to SMI/GSI qp's. This return code means that the SMI/GSI
QP is already allocated.
IB_INVALID_PD
Invalid protection domain supplied.
IB_INVALID_PORT
Invalid port number supplied.
IB_UNSUPPORTED
Raw datagram unsupported.
IB_INVALID_PARAMETER
The parameter p_create_attr is not valid.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> This verb is privileged and only available in kernel mode. The User mode
clients that need access to SMI/GSI qp's is recommended to do this via
a higher level of abstraction.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo573">ci_create_qp</a>, <a href="#robo601">ci_query_qp</a>, <a href="#robo590">ci_modify_qp</a>, <a href="#robo580">ci_destroy_qp</a>
</pre>
</span>
<hr />
<h2><a name="robo575">[Functions]<a name="Verbs2fci5fdeallocate5fpd">
Verbs/ci_deallocate_pd</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_deallocate_pd</strong> -- Deallocate a protection domain object.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_deallocate_pd</strong>) (
IN ib_pd_handle_t h_pd );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine deallocates a pd that is allocated via the <a href="#robo564">ci_allocate_pd</a>()
call. The PD cannot be deallocated if it is still bound to a QP, any memory
region, memory window or address vector.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_pd
[in] Handle allocated via the <a href="#robo564">ci_allocate_pd</a>()
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
PD is freed successfully
IB_INVALID_PD_HANDLE
pd_handle is invalid
IB_RESOURCE_BUSY
PD is probably still bound to some resource
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo564">ci_allocate_pd</a>
</pre>
</span>
<hr />
<h2><a name="robo576">[Functions]<a name="Verbs2fci5fderegister5fmr">
Verbs/ci_deregister_mr</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_deregister_mr</strong> -- Deregister a memory region
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_deregister_mr</strong>) (
IN const ib_mr_handle_t h_mr );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine deregisters a memory region from the HCA. The region can
de-registered only if there are no existing memory windows bound to
this region, and if no existing shared memory regions were registered
that refers to the same set of physical pages associated with the memory
handle. If there are outstanding work requests referring to this memory
region, then after this call is successful, those work requests will
complete with WRS_LOCAL_PROTECTION_ERR.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_mr
[in] Memory handle that is being de-registered.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The memory de-registration was successful
IB_INVALID_MR_HANDLE
The memory handle supplied is not a valid memory handle.
IB_RESOURCE_BUSY
The memory region has active windows bound.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"></span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo602">ci_register_mr</a>, <a href="#robo603">ci_register_pmr</a>, <a href="#robo604">ci_register_smr</a>
</pre>
</span>
<hr />
<h2><a name="robo577">[Functions]<a name="Verbs2fci5fdestroy5fav">
Verbs/ci_destroy_av</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_destroy_av</strong> -- Destroy the address vector
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_destroy_av</strong>) (
IN const ib_av_handle_t h_av );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine destroys the specified address handle. After the routine
returns, this address handle cannot be used to reference the destination.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_av
[in] Handle that needs to be destroyed.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
Operation was successful.
IB_INVALID_AV_HANDLE
The address vector handle was invalid
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo570">ci_create_av</a>
</pre>
</span>
<hr />
<h2><a name="robo578">[Functions]<a name="Verbs2fci5fdestroy5fcq">
Verbs/ci_destroy_cq</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_destroy_cq</strong> -- Destroy a completion queue.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_destroy_cq</strong>) (
IN const ib_cq_handle_t h_cq );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> Destroys a completion queue. If any queue pairs are still bound
to this CQ, the attempt to destroy will fail, and the CQ and associated
resources are *NOT* destroyed.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> cq_handle
[in] Handle to the cq that is to be destroyed.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The intend to destroy the completion queue is registered successfully.
The destroy_callback function will be invoked when it is safe and
guarantees that no more completion callbacks will be invoked for
this CQ. Any pending CQ notifications are discarded.
IB_INVALID_CQ_HANDLE
The CQ handle is invalid.
IB_RESOURCE_BUSY
Queue pairs may still be bound to this completion queue.
IB_INVALID_PARAMETER
one of the parameters was NULL.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo571">ci_create_cq</a>
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> This call cannot be called from any of the notification functions invoked
by the <a href="#robo1">Verbs</a> driver. For e.g. the completion handler or the async error
callback provided during the <a href="#robo591">ci_open_ca</a>() call. The call will block until
all references to this adapter object is closed which includes all the
pending callbacks returning back to the verbs provider driver.
</pre>
</span>
<hr />
<h2><a name="robo579">[Functions]<a name="Verbs2fci5fdestroy5fmw">
Verbs/ci_destroy_mw</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_destroy_mw</strong> -- Destroy a memory window.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_destroy_mw</strong>) (
IN const ib_mw_handle_t h_mw );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine deallocates a window entry created via a <a href="#robo572">ci_create_mw</a>.
Once this operation is complete, the channel interface guarantees that
no future remote accesses will be permitted to this window entry.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_mw
[in] Handle to the memory window that is being destroyed.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The destroy window request completed successfully.
IB_INVALID_MW_HANDLE
memw_handle supplied is invalid.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> Deallocate memory window implicitly means the window is also unbound
once the call completes successfully. Any future remote access with
the same R_KEY should fail with protection violation.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo572">ci_create_mw</a>
</pre>
</span>
<hr />
<h2><a name="robo580">[Functions]<a name="Verbs2fci5fdestroy5fqp">
Verbs/ci_destroy_qp</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_destroy_qp</strong> -- Destroy the specified Queue Pair.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_destroy_qp</strong>) (
IN const ib_qp_handle_t h_qp,
IN const uint64_t timewait );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> Destroys the associated QP. The QP could have outstanding work requests
when this call is made. Any outstanding work requests *SHALL NOT* be
completed after this routine returns.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_qp
[in] Handle to the qp that needs to be destroyed.
timewait
[in] Time (in microseconds) at which the QP should leave
the timewait state and can be reused.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The intend to destroy this queue pair is registered and no further
work requests will be processed. When no pending callbacks are in
progress, the destroy_callback function is invoked which marks the
destruction of the resource. The consumer can be guaranteed that
no future callbacks will be propagated on behalf of this resource.
IB_INVALID_QP_HANDLE
The handle passed is invalid.
IB_RESOURCE_BUSY
If the queue pair is a unreliable datagram service type, and
is still bound to a multicast group.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> This call cannot be called from any of the notification functions invoked
by the <a href="#robo1">Verbs</a> driver. For e.g. the completion handler or the async error
callback provided during the <a href="#robo591">ci_open_ca</a>() call. The call will block until
all references to this adapter object is closed which includes all the
pending callbacks returning back to the verbs provider driver.
If the CQ associated with this QP is still not destroyed, the completions
on behalf of this QP can still be pulled via the <a href="#robo593">ci_poll_cq</a>() call. Any
resources allocated by the Channel Interface must be deallocated as part
of this call.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo573">ci_create_qp</a>, <a href="#robo574">ci_create_spl_qp</a>
</pre>
</span>
<hr />
<h2><a name="robo581">[Functions]<a name="Verbs2fci5fdetach5fmcast">
Verbs/ci_detach_mcast</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_detach_mcast</strong> -- Detach a queue pair from a multicast group
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_detach_mcast</strong>) (
IN const ib_mcast_handle_t h_mcast );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine detaches a queue pair from its previously associated multicast
group.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_mcast
[in] The multicast handle passed back to consumer after the
ci_mcast_attach call.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The qp was successfully detached from the multicast group.
IB_INVALID_MCAST_HANDLE
mcast_handle supplied is an invalid handle
IB_INVALID_PARAMETER
One of the parameters was NULL.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo566">ci_attach_mcast</a>
</pre>
</span>
<hr />
<h2><a name="robo582">[Functions]<a name="Verbs2fci5fenable5fcq5fnotify">
Verbs/ci_enable_cq_notify</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_enable_cq_notify</strong> -- Invoke the Completion handler, on next entry added.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_enable_cq_notify</strong>) (
IN const ib_cq_handle_t h_cq,
IN const boolean_t solicited );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine instructs the channel interface to invoke the completion
handler when the next completion queue entry is added to this CQ.
Please refer to Volume 1, of the InfiniBand specification for a complete
description.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_cq
[in] Handle to the CQ on which the notification is being enabled.
solicited
[in] A boolean flag indicating whether the request is to generate a
notification on the next entry or on the next solicited entry
being added to the completion queue.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The notification request was registered successfully.
IB_INVALID_CQ_HANDLE
cq_handle supplied is not a valid handle.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> The consumer cannot call a request for notification without emptying
entries from the CQ. i.e if a consumer registers for a notification
request in the completion callback before pulling entries from the
CQ via <a href="#robo593">ci_poll_cq</a>, the notification is not generated for completions
already in the CQ. For e.g. in the example below, if there are no calls
to <a href="#robo593">ci_poll_cq</a>() after the <strong>ci_enable_cq_notify</strong>(). For any CQ entries added
before calling this <strong>ci_enable_cq_notify</strong>() call, the consumer does not
get a completion notification callback. In order to comply with the verb
spec, consumer is supposed to perform a <a href="#robo593">ci_poll_cq</a>() after the
<strong>ci_enable_cq_notify</strong>() is made to retrive any entries that might have
been added to the CQ before the CI registers the notification enable.
while ((ret_val = <a href="#robo593">ci_poll_cq</a>(cq_handle, &free_list, &done_list)
== FSUCCESS))
{
process entries;
}
if (ret_val == IB_NOT_FOUND)
<strong>ci_enable_cq_notify</strong>(cq_handle);
// Need to perform a <a href="#robo593">ci_poll_cq</a>()
// after the enable.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo571">ci_create_cq</a>, <a href="#robo592">ci_peek_cq</a>, <a href="#robo593">ci_poll_cq</a>, <a href="#robo583">ci_enable_ncomp_cq_notify</a>
</pre>
</span>
<hr />
<h2><a name="robo583">[Functions]<a name="Verbs2fci5fenable5fncomp5fcq5fnotify">
Verbs/ci_enable_ncomp_cq_notify</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_enable_ncomp_cq_notify</strong> -- Invoke the Completion handler when the next
N completions are added.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_enable_ncomp_cq_notify</strong>) (
IN const ib_cq_handle_t h_cq,
IN const uint32_t n_cqes );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine instructs the channel interface to invoke the completion
handler when the next N completions have been added to this CQ.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_cq
[in] Handle to the CQ on which the notification is being enabled.
n_cqes
[in] The number of completion queue entries to be added to the
completion queue before notifying the client. This value must
greater than or equal to one and less than or equal to the size
of the completion queue.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The notification request was registered successfully.
IB_INVALID_CQ_HANDLE
cq_handle supplied is not a valid handle.
IB_INVALID_PARAMETER
The requested number of completion queue entries was invalid.
IB_UNSUPPORTED
This operation is not supported by the channel adapter.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> This routine instructs the channel interface to invoke the completion
handler when the next N completions have been added to this CQ regardless
of the completion type (solicited or unsolicited). Any CQ entries that
existed before the rearm is enabled will not result in a call to the
handler. Support for this operation is optional by a channel adapter
vendor.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo571">ci_create_cq</a>, <a href="#robo592">ci_peek_cq</a>, <a href="#robo593">ci_poll_cq</a>, <a href="#robo582">ci_enable_cq_notify</a>
</pre>
</span>
<hr />
<h2><a name="robo584">[Structures]<a name="Verbs2fci5finterface5ft">
Verbs/ci_interface_t</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_strutures.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_interface_t</strong> -- Interface holding Channel Interface API's
</pre>
</span><p><strong>PURPOSE</strong></p>
<span class="PURPOSE"><pre> The following structure is supplied by a Channel Interface
providing verbs functionality.
</pre>
</span><p><strong>SOURCE</strong></p>
<span class="SOURCE"><pre>#define MAX_LIB_NAME 32
typedef struct _ci_interface
{
net64_t guid;
/*
* Device object of the HCA. In Windows, this is a pointer to the PDO
* for the HCA device.
*/
void *p_hca_dev;
/*
* Vendor ID, Device ID, Device Revision of the HCA
* libname refers to the user mode library to load
* to support direct user mode IO. If vendor does not support one
* then the fields must be initialized to all zero's.
*/
uint32_t vend_id;
uint16_t dev_id;
uint16_t dev_revision;
char libname[MAX_LIB_NAME];
/*
* Version of the header file this interface export can handle
*/
uint32_t version;
/*
* HCA Access <a href="#robo1">Verbs</a>
*/
<a href="#robo591">ci_open_ca</a> open_ca;
ci_um_open_ca_t um_open_ca;
<a href="#robo597">ci_query_ca</a> query_ca;
<a href="#robo587">ci_modify_ca</a> modify_ca;
<a href="#robo568">ci_close_ca</a> close_ca;
<a href="#robo606">ci_um_close_ca_t</a> um_close_ca;
<a href="#robo609">ci_vendor_call</a> vendor_call;
/*
* Protection Domain
*/
<a href="#robo564">ci_allocate_pd</a> allocate_pd;
<a href="#robo575">ci_deallocate_pd</a> deallocate_pd;
/*
* Address Vector Management <a href="#robo1">Verbs</a>
*/
<a href="#robo570">ci_create_av</a> create_av;
<a href="#robo596">ci_query_av</a> query_av;
<a href="#robo586">ci_modify_av</a> modify_av;
<a href="#robo577">ci_destroy_av</a> destroy_av;
/*
* QP Management <a href="#robo1">Verbs</a>
*/
<a href="#robo573">ci_create_qp</a> create_qp;
<a href="#robo574">ci_create_spl_qp</a> create_spl_qp;
<a href="#robo590">ci_modify_qp</a> modify_qp;
<a href="#robo601">ci_query_qp</a> query_qp;
<a href="#robo580">ci_destroy_qp</a> destroy_qp;
/*
* Completion Queue Management <a href="#robo1">Verbs</a>
*/
<a href="#robo571">ci_create_cq</a> create_cq;
<a href="#robo605">ci_resize_cq</a> resize_cq;
<a href="#robo598">ci_query_cq</a> query_cq;
<a href="#robo578">ci_destroy_cq</a> destroy_cq;
/*
* Memory Management <a href="#robo1">Verbs</a>
*/
<a href="#robo602">ci_register_mr</a> register_mr;
<a href="#robo603">ci_register_pmr</a> register_pmr;
<a href="#robo599">ci_query_mr</a> query_mr;
<a href="#robo588">ci_modify_mr</a> modify_mr;
<a href="#robo589">ci_modify_pmr</a> modify_pmr;
<a href="#robo604">ci_register_smr</a> register_smr;
<a href="#robo576">ci_deregister_mr</a> deregister_mr;
/*
* Memory Window <a href="#robo1">Verbs</a>
*/
<a href="#robo572">ci_create_mw</a> create_mw;
<a href="#robo600">ci_query_mw</a> query_mw;
<a href="#robo567">ci_bind_mw</a> bind_mw;
<a href="#robo579">ci_destroy_mw</a> destroy_mw;
/*
* Work Request Processing <a href="#robo1">Verbs</a>
*/
<a href="#robo595">ci_post_send</a> post_send;
<a href="#robo594">ci_post_recv</a> post_recv;
/*
* Completion Processing and
* Completion Notification Request <a href="#robo1">Verbs</a>.
*/
<a href="#robo592">ci_peek_cq</a> peek_cq; /* Optional */
<a href="#robo593">ci_poll_cq</a> poll_cq;
<a href="#robo582">ci_enable_cq_notify</a> enable_cq_notify;
<a href="#robo583">ci_enable_ncomp_cq_notify</a> enable_ncomp_cq_notify; /* Optional */
/*
* Multicast Support <a href="#robo1">Verbs</a>
*/
<a href="#robo566">ci_attach_mcast</a> attach_mcast;
<a href="#robo581">ci_detach_mcast</a> detach_mcast;
/*
* Local MAD support, for HCA's that do not support
* Agents in the HW.
*/
<a href="#robo585">ci_local_mad</a> local_mad;
} <strong>ci_interface_t</strong>;
</pre>
</span>
<hr />
<h2><a name="robo585">[Functions]<a name="Verbs2fci5flocal5fmad">
Verbs/ci_local_mad</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_local_mad</strong> -- Request a mad to be processed by the local adapter.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_local_mad</strong>) (
IN const ib_ca_handle_t h_ca,
IN const uint8_t port_num,
IN const <a href="./ib_types_h.html#robo396">ib_mad_t</a> *p_mad_in,
OUT <a href="./ib_types_h.html#robo396">ib_mad_t</a> *p_mad_out );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine is OPTIONAL for the channel interface. This is required
for adapters which do not have the agents such as Subnet Management
agent (SMA) Or the GSA in the <a href="#robo1">Verbs</a> Provider driver.
hardware, for all such adapters the exact queue pair management of
special queue pairs happen above the channel interface. This routine
is used to perform local operations, since there is no agent below the
channel interface. For e.g: If a Subnet Management packet (SMP) to
set PORT_STATE is received, this reception is processed above the channel
interface, then this call is done to set the port state on the local
adapter. On successful return, the response is generated and sent to the
Subnet Manager.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_ca
[in] A handle to the channel adapter that should process the MAD.
This must be the same adapter that the MAD was received on.
port_num
[in] port number to which this request is directed is to be sent.
p_mad_in
[in] pointer to a management datagram (MAD) structure containing
the command to be processed.
p_mad_out
[out] Response packet after processing the command. The storage to this
must be allocated by the consumer.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
Command processed successfully.
IB_INVALID_CA_HANDLE
The HCA handle supplied is not valid.
IB_INVALID_PORT
The port number supplied is invalid.
</pre>
</span><p><strong>PORTABILITY</strong></p>
<span class="PORTABILITY"><pre> Kernel Mode only
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> This call is provided to aid adapters that don't have a agent functionality
built in the channel interface. Some adapters do have a local processor
to process these packets, hence even for local port management, we can
use the same mechanism we use to configure external nodes by using a
hop counter = 1 in the MAD packets. If the SMA indicates it has a local
sma in the <a href="./ib_types_h.html#robo20">ib_ca_attr_t</a>, then the packets are posted to the adapter
instead of making a private call to the adapter.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo597">ci_query_ca</a>, ci_ca_attr_t
</pre>
</span>
<hr />
<h2><a name="robo586">[Functions]<a name="Verbs2fci5fmodify5fav">
Verbs/ci_modify_av</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_modify_av</strong> -- Change the address vector referred by the av_handle
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_modify_av</strong>) (
IN const ib_av_handle_t h_av,
IN const <a href="./ib_types_h.html#robo17">ib_av_attr_t</a> *p_av_attr,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine allows a consumer to modify the address information
passed.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_av
[in] Address handle that needs to be updated with new info.
p_av_attr
[in] New address vector to associate with the addr_handle.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
Operation was successful
IB_INVALID_AV_HANDLE
The address vector handle was invalid
IB_INVALID_PORT
Invalid port number passed in the Address Vector.
IB_INVALID_PARAMETER
The parameter p_av_attr is not valid.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> The values in the p_av_attr is not validated for correctness. The values
in the attribute such as port number, protection domain etc are validated
during processing by the channel adapter. If the attribute validation fails
a processing error IB_WCS_LOCAL_OP_ERR.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo570">ci_create_av</a>, <a href="#robo596">ci_query_av</a>
</pre>
</span>
<hr />
<h2><a name="robo587">[Functions]<a name="Verbs2fci5fmodify5fca">
Verbs/ci_modify_ca</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_modify_ca</strong> -- Modify port attributes and error counters
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_modify_ca</strong>) (
IN const ib_ca_handle_t h_ca,
IN const uint8_t port_num,
IN const <a href="./ib_types_h.html#robo21">ib_ca_mod_t</a> ca_mod,
IN const <a href="./ib_types_h.html#robo159">ib_port_attr_mod_t</a> *p_port_attr_mod );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> Modifies either the P_KEY/Q_KEY violation counters, or sets the capability
mask in the port attributes. This is effectively translated to PORTINFO
values responded later when a MAD from SM or another node arrives to
retrieve port related attributes.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_ca
[in] Handle returned by previous call to <a href="#robo591">ci_open_ca</a>()
port_num
[in] Port number, which needs to be modified.
ca_mod
[in] Command mask to perform operations on.
p_port_attr_mod
[in] port attribute which needs this change to be performed.
if the capability bit is set, then that corresponding
port capability is turned on.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
Modify port attributes was performed
IB_INVALID_PORT
Invalid port number supplied in port_att.
IB_INVALID_PARAMETER
Unknown Command supplied in port_attr.
IB_UNSUPPORTED
Optional Q_KEY and P_KEY violation counters are not supported.
IB_INVALID_CA_HANDLE
h_ca is invalid
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> No ownership checks are performed in the <a href="#robo1">Verbs</a> Provider Driver.
All such permission checks are to be performed by the IB access layer
before passing requests down to the HCA driver. These operations can be
performed only by the special QP owner. Either the QP0 or QP1. Since port
attributes is really maintained by the QP0 for SMA to respond with correct
values, but the agent capability is really a QP1 functionality.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo591">ci_open_ca</a>, <a href="#robo597">ci_query_ca</a>, <a href="#robo568">ci_close_ca</a>
</pre>
</span>
<hr />
<h2><a name="robo588">[Functions]<a name="Verbs2fci5fmodify5fmr">
Verbs/ci_modify_mr</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_modify_mr</strong> -- Modify some or all parameters of a memory region.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_modify_mr</strong>) (
IN const ib_mr_handle_t h_mr,
IN const <a href="./ib_types_h.html#robo121">ib_mr_mod_t</a> mr_modify_mask,
IN const <a href="./ib_types_h.html#robo120">ib_mr_create_t</a>* const p_mr_create OPTIONAL,
OUT net32_t* const p_lkey,
OUT net32_t* const p_rkey,
IN const ib_pd_handle_t h_pd OPTIONAL,
IN boolean_t um_call );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine modifies attributes of the specified memory region
irrespective of whether the handle was obtained via <a href="#robo602">ci_register_mr</a>
or <a href="#robo603">ci_register_pmr</a>. This verb conceptually performs a de-registration
followed by a <a href="#robo602">ci_register_mr</a>.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_mr
[in] Handle to the memory region whose attributes are to be modified.
mr_modify_mask
[in] Command specifying which parts of the mem_region is valid. The
command is specified as a bit mask.
p_mr_create
[in] Desired attributes that need to be modified for mem_handle.
This is an optional parameter which can be NULL if mr_modify_mask
is set to IB_MR_MOD_PD.
p_lkey
[out] The new l_key for this newly registered memory region.
p_rkey
[out] The new r_key for this newly registered memory region.
The verbs provider is required to give this in the expected ordering
on the wire. When rkey's are exchanged between remote nodes, no
swapping of this data will be performed.
h_pd
[in] This parameter is valid only if the IB_MR_MOD_PD flag is set
in the mr_modify_req parameter. This field supplies the new
protection domain to which the modified region should be
associated with.
um_call
[in] Boolean indicating whether the registration originated in user-mode.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The modify memory region request completed successfully.
IB_RESOURCE_BUSY
The memory region has windows bound to it.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to complete the request.
IB_INVALID_MR_HANDLE
The memory handle supplied is not a valid memory region handle.
IB_INVALID_PERMISSION
Invalid access rights specified.
IB_INVALID_PARAMETER
A reference to the lkey or rkey was not provided or the specified
modify mask is invalid.
IB_INVALID_SETTING
The specified memory region attributes are invalid.
IB_INVALID_PD_HANDLE
Protection domain handle supplied is not valid.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> Remote and Atomic access settings in ib_access_ctrl_t, requires local
write access to be enabled.
TBD: How to handle shared memory region being passed to modify_mem?
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo602">ci_register_mr</a>, <a href="#robo603">ci_register_pmr</a>, <a href="#robo604">ci_register_smr</a>
</pre>
</span>
<hr />
<h2><a name="robo589">[Functions]<a name="Verbs2fci5fmodify5fpmr">
Verbs/ci_modify_pmr</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_modify_pmr</strong> -- Modify some or all parameters of a memory region.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_modify_pmr</strong>) (
IN const ib_mr_handle_t h_mr,
IN const <a href="./ib_types_h.html#robo121">ib_mr_mod_t</a> mr_modify_mask,
IN const <a href="./ib_types_h.html#robo147">ib_phys_create_t</a>* const p_pmr_create,
IN OUT uint64_t* const p_vaddr,
OUT net32_t* const p_lkey,
OUT net32_t* const p_rkey,
IN const ib_pd_handle_t h_pd OPTIONAL,
IN boolean_t um_call );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine modifies attributes of the specified memory region
irrespective of whether the handle was obtained via <a href="#robo602">ci_register_mr</a>
or <a href="#robo603">ci_register_pmr</a>. This verb conceptually performs a de-registration
followed by a <a href="#robo603">ci_register_pmr</a>.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_mr
[in] Handle to the memory region whose attributes are to be modified.
mr_modify_mask
[in] Command specifying which parts of the mem_region is valid. The
command is specified as a bit mask.
p_pmr_create
[in] Desired attributes that need to be modified for mem_handle.
p_vaddr
[in/out] On input, references the requested virtual address for the
start of the physical region. On output, references the actual
virtual address assigned to the registered region.
p_lkey
[out] The new l_key for this newly registered physical memory region.
p_rkey
[out] The new r_key for this newly registered physical memory region.
VPD is required to give this in the expected ordering on the wire. When
rkey's are exchanged between remote nodes, no swapping of this data
will be performed.
h_pd
[in] This parameter is valid only if the IB_MR_MOD_PD flag is set
in the mr_modify_req parameter. This field supplies the new
protection domain to which the modified region should be
associated with.
um_call
[in] Boolean indicating whether the registration originated in user-mode.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The modify memory region request completed successfully.
IB_RESOURCE_BUSY
The memory region has windows bound to it.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to complete the request.
IB_INVALID_MR_HANDLE
The memory handle supplied is not a valid memory region handle.
IB_INVALID_PERMISSION
Invalid access rights specified.
IB_INVALID_PARAMETER
A reference to the virtual address, lkey, rkey was not provided or
the specified modify mask is invalid.
IB_INVALID_SETTING
The specified memory region attributes are invalid.
</pre>
</span><p><strong>PORTABILITY</strong></p>
<span class="PORTABILITY"><pre> Kernel Mode only
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> Remote and Atomic access settings in ib_access_ctrl_t, requires local
write access to be enabled.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo602">ci_register_mr</a>, <a href="#robo603">ci_register_pmr</a>, <a href="#robo604">ci_register_smr</a>
</pre>
</span>
<hr />
<h2><a name="robo590">[Functions]<a name="Verbs2fci5fmodify5fqp">
Verbs/ci_modify_qp</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_modify_qp</strong> -- Modify attributes of the specified QP.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_modify_qp</strong>) (
IN const ib_qp_handle_t h_qp,
IN const <a href="./ib_types_h.html#robo167">ib_qp_mod_t</a> *p_modify_attr,
OUT <a href="./ib_types_h.html#robo165">ib_qp_attr_t</a> *p_qp_attr OPTIONAL,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine is used to modify the qp states or other attributes of the
QP. On successful completion, the requested state transition is performed
and the QP is transitioned to the required state.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_qp
[in] Handle to the queue pair whose state is to be modified.
p_modify_attr
[in] Specifies what attributes need to be modified in the qp.
p_qp_attr
[out] QP attributes after the qp is successfully created.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The operation was successful and the QP attributes are modified
to the requested state.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to complete the requested operation.
IB_INVALID_QP_HANDLE
Invalid QP handle was passed.
IB_UNSUPPORTED
Requested operation is not supported, for e.g. Atomic operations.
IB_QP_INVALID_STATE
Invalid state transition request. Current QP state not in allowable
state.
IB_INVALID_PKEY
Pkey specified in modify request not valid entry in P_KEY table. Or
index is out of range.
IB_INVALID_APM_STATE
Invalid automatic path migration state specified in the request.
IB_INVALID_PARAMETER
The parameter p_modify_attr is not valid.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> Refer to Table 79 in chapter 11, Volume 1 of the InfiniBand Specifications.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo573">ci_create_qp</a>, <a href="#robo574">ci_create_spl_qp</a>, <a href="#robo601">ci_query_qp</a>
</pre>
</span>
<hr />
<h2><a name="robo591">[Functions]<a name="Verbs2fci5fopen5fca">
Verbs/ci_open_ca</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_open_ca</strong> -- open and possibly obtain a handle to access the HCA.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_open_ca</strong>) (
IN const <a href="./ib_types_h.html#robo409">ib_net64_t</a> ca_guid,
IN const <a href="#robo569">ci_completion_cb_t</a> pfn_completion_cb,
IN const <a href="#robo565">ci_async_event_cb_t</a> pfn_async_event_cb,
IN const void* const ca_context,
OUT ib_ca_handle_t *ph_ca );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine returns a handle to an open instance of a HCA. Client can call
this routine to retrieve a new open instance. Only one instance of the
open call is active at any time. If a duplicate open is called by the
consumer or any other consumer, it IB_RESOURCE_BUSY error status is
returned.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> ca_guid
[in] The HCA adapter's EUI64 identifier. Clients would use other
enumeration API's to locate all available adapters and their
guids in a system, e.g. GetCaGuids(), maintained by the IB
Access Layer. User mode consumers also have the same mechanism
to retrieve this information.
pfn_completion_cb
[in] Completion Handler, one per open instance.
pfn_async_event_cb
[in] Asynchronous event handler, one per open instance.
ca_context
[in] <a href="#robo1">Verbs</a> consumer supplied value, which is returned on calls to
handlers which in turn is used by clients to identify the
open instance.
ph_ca
[out] Pointer to a handle to the newly open instance of the CA returned
by the <a href="#robo1">Verbs</a> Provider.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The HCA is successfully opened and returned handle is valid.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to satisfy request.
IB_INVALID_PARAMETER
Callback routine are not provided, GUID value is zero, or ph_ca is NULL
IB_RESOURCE_BUSY
The interface is already open by another consumer.
IB_NOT_FOUND
ca_guid passed is not valid
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo597">ci_query_ca</a>, <a href="#robo587">ci_modify_ca</a>, <a href="#robo568">ci_close_ca</a>
</pre>
</span>
<hr />
<h2><a name="robo592">[Functions]<a name="Verbs2fci5fpeek5fcq">
Verbs/ci_peek_cq</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_peek_cq</strong>
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> Returns the number of entries currently on the completion queue.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_peek_cq</strong>) (
IN const ib_cq_handle_t h_cq,
OUT uint32_t* const p_n_cqes );
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_cq
[in] Handle to the completion queue to peek.
p_n_cqes
[out] The number of completion entries on the CQ.
RETURN VALUES
IB_SUCCESS
The peek operation completed successfully.
IB_INVALID_CQ_HANDLE
The completion queue handle was invalid.
IB_INVALID_PARAMETER
A reference to the completion queue entry count was not provided.
IB_UNSUPPORTED
This operation is not supported by the channel adapter.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> The value returned is a snapshot of the number of compleiton queue
entries curently on the completion queue. Support for this operation
is optional by a channel adapter vendor.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo571">ci_create_cq</a>, <a href="#robo593">ci_poll_cq</a>, <a href="#robo582">ci_enable_cq_notify</a>, <a href="#robo583">ci_enable_ncomp_cq_notify</a>
</pre>
</span>
<hr />
<h2><a name="robo593">[Functions]<a name="Verbs2fci5fpoll5fcq">
Verbs/ci_poll_cq</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_poll_cq</strong> -- Retrieve a work completion record from a completion queue
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_poll_cq</strong>) (
IN const ib_cq_handle_t h_cq,
IN OUT <a href="./ib_types_h.html#robo220">ib_wc_t</a>** const pp_free_wclist,
OUT <a href="./ib_types_h.html#robo220">ib_wc_t</a>** const pp_done_wclist );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine retrieves a work completion entry from the specified
completion queue. The contents of the data returned in a work completion
is specified in <a href="./ib_types_h.html#robo220">ib_wc_t</a>.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_cq
[in] Handle to the completion queue being polled.
pp_free_wclist
[in out] A list of work request structures provided by the consumer
for the channel interface to return completed Completion Queue
entries. If not all the entries are consumed, this list holds the
list of un-utilized completion entries provided back to the consumer.
pp_done_wclist
[out] A list of work completions retrieved from the completion queue
and successfully processed.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
Poll completed successfully and found one or more entries. If on
completion the pp_free_wclist is empty, then there are potentially more
entries and the consumer must continue to retrieve entries.
IB_INVALID_CQ_HANDLE
The cq_handle supplied is not valid.
IB_NOT_FOUND
There were no completion entries found in the specified CQ.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo571">ci_create_cq</a>, <a href="#robo595">ci_post_send</a>, <a href="#robo594">ci_post_recv</a>, <a href="#robo567">ci_bind_mw</a>
</pre>
</span>
<hr />
<h2><a name="robo594">[Functions]<a name="Verbs2fci5fpost5frecv">
Verbs/ci_post_recv</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_post_recv</strong> -- Post a work request to the receive queue of a queue pair.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_post_recv</strong>) (
IN const ib_qp_handle_t h_qp,
IN <a href="./ib_types_h.html#robo185">ib_recv_wr_t</a>* const p_recv_wr,
OUT <a href="./ib_types_h.html#robo185">ib_recv_wr_t</a> **pp_failed );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine allows to queue a work request to the receive side of a
queue pair. The work_req holds necessary data to satisfy an incoming
receive message. If an attempt is made to queue more work requests than
what is available, an error is returned.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_qp
[in] Handle to the queue pair to which the receive work request is being
posted.
p_recv_wr
[in] Holds the WRs to be posted to the receive queue.
pp_failed
[out] If any entry could not be posted with the CI, then this points
to the first WR that completed unsuccessfully. If all entries are
posted, then this field is set to NULL on successful exit.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> Any unsuccessful status indicates the status of the first failed request.
IB_SUCCESS
The work request was successfully queued to the receive side of the QP.
IB_INVALID_QP_HANDLE
qp_handle supplied is not valid.
IB_INSUFFICIENT_RESOURCES
The qp has exceeded its receive queue depth than what is has been
configured.
IB_INVALID_WR_TYPE
Invalid work request type found in the request.
IB_INVALID_QP_STATE
QP was in reset or init state.
(TBD: there may be an errata that allows posting in init state)
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo595">ci_post_send</a>, <a href="#robo593">ci_poll_cq</a>.
</pre>
</span>
<hr />
<h2><a name="robo595">[Functions]<a name="Verbs2fci5fpost5fsend">
Verbs/ci_post_send</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_post_send</strong> -- Post a work request to the send side of a queue pair.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_post_send</strong>) (
IN const ib_qp_handle_t h_qp,
IN <a href="./ib_types_h.html#robo209">ib_send_wr_t</a>* const p_send_wr,
OUT <a href="./ib_types_h.html#robo209">ib_send_wr_t</a> **pp_failed );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine posts a work request to the send side of the queue pair.
The different types of work request that can be posted are explained in
the ib_wr_t structure. For exact details on ordering rules please consult
the Volume 1, of the InfiniBand Specifications. If there is more
outstanding requests posted that what the queue is configured for, an
immediate error is returned.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_qp
[in] The queue pair to which this work request is being submitted.
p_send_wr
[in] A pointer to the head of the list that must be posted to the
Send Queue.
pp_failed
[out] A pointer to the head of the list that holds the failed WRs.
If all the entries provided are posted with the CI, then this parameter
would be set to NULL.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> Any unsuccessful status indicates the status of the first failed request.
IB_SUCCESS
All the work requests are completed successfully
IB_INVALID_QP_HANDLE
The qp_handle supplied is invalid.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to complete the request.
There are no more work elements in the channel interface to
process this request, and the total outstanding work request has
been exceeded.
IB_INVALID_WR_TYPE
The work request type was not valid.
IB_INVALID_QP_STATE
The queue pair is either in Reset, Init, RTR or Error state.
IB_INVALID_MAX_SGE
The work request has too many scatter gather elements than what the
QP is configured.
IB_UNSUPPORTED
Atomics or Reliable datagram request is not supported by this HCA.
IB_INVALID_ADDR_HANDLE
Address handle supplied in the work request is invalid.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> Please refer to Table 81 and Table 82 for allowed operation types
on different types of queue pairs, and the different modifiers
acceptable for the work request for different QP service types.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo594">ci_post_recv</a>, <a href="#robo593">ci_poll_cq</a>
</pre>
</span>
<hr />
<h2><a name="robo596">[Functions]<a name="Verbs2fci5fquery5fav">
Verbs/ci_query_av</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_query_av</strong> -- Obtain the address vector associated with the handle
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_query_av</strong>) (
IN const ib_av_handle_t h_av,
OUT <a href="./ib_types_h.html#robo17">ib_av_attr_t</a> *p_av_attr,
OUT ib_pd_handle_t *ph_pd,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine returns the address vector and pd_handle associated with the
av_handle.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_av
[in] Handle to the address vector
p_av_attr
[out] address vector data referred by the av_handle
ph_pd
[out] pd handle associated with the av_handle
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
returned values are valid
IB_INVALID_AV_HANDLE
The address vector handle was invalid
IB_INVALID_PARAMETER
One of the p_av_attr or ph_pd parameters was NULL.
IB_INVALID_PORT
Invalid port number passed in the Address Vector.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo570">ci_create_av</a>, <a href="#robo586">ci_modify_av</a>
</pre>
</span>
<hr />
<h2><a name="robo597">[Functions]<a name="Verbs2fci5fquery5fca">
Verbs/ci_query_ca</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_query_ca</strong> -- Query the attributes of the HCA
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_query_ca</strong>) (
IN const ib_ca_handle_t h_ca,
OUT <a href="./ib_types_h.html#robo20">ib_ca_attr_t</a> *p_ca_attr OPTIONAL,
IN OUT uint32_t *p_size,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine retrieves vital information about this hca. It returns
necessary information about HCA guid, port guids, LID's assigned by
the master SM. Clients can use this information to communicate with the
Master SM node to perform path queries etc.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_ca
[in] Handle returned by an earlier call to <a href="#robo591">ci_open_ca</a>()
p_ca_attr
[out] CA attribute of this Host Channel adapter
p_size
[in/out] On input, this references the size of the data buffer
referenced by the p_ca_attr parameter.
On output, the number of bytes used or needed to copy all CA
attribute information.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The attribute structure is returned completely.
IB_INSUFFICIENT_MEMORY
The size of the p_ca_attr buffer, specified through p_size, is
insufficient to store all of the CA attribute information.
IB_INVALID_CA_HANDLE
h_ca is invalid
IB_INVALID_PARAMETER
p_size is NULL.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> Users may obtain the size of the data buffer required to obtain the
CA attributes by calling this function with p_ca_attr set to NULL.
The channel interface will then return the necessary size in the
variable referenced by the p_size parameter. The caller can then allocate
exact size and call this routine again. No partial information is returned
if the size is not sufficient.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo591">ci_open_ca</a>, <a href="#robo587">ci_modify_ca</a>
</pre>
</span>
<hr />
<h2><a name="robo598">[Functions]<a name="Verbs2fci5fquery5fcq">
Verbs/ci_query_cq</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_query_cq</strong> -- Query the number of entries configured for the CQ.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_query_cq</strong>) (
IN const ib_cq_handle_t h_cq,
OUT uint32_t *p_size,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine returns the maximum number of entries this completion
queue is configured.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_cq
[in] Handle to the completion queue
p_size
[out] The number of entries the completion queue is configured to hold
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The call completed successfully, and the returned values are valid
IB_INVALID_CQ_HANDLE
The cq_handle passed is invalid.
IB_INVALID_PARAMETER
one of the parameters was NULL.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo571">ci_create_cq</a>, <a href="#robo605">ci_resize_cq</a>
</pre>
</span>
<hr />
<h2><a name="robo599">[Functions]<a name="Verbs2fci5fquery5fmr">
Verbs/ci_query_mr</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_query_mr</strong> -- Query attributes of a registered memory region
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_query_mr</strong>) (
IN const ib_mr_handle_t h_mr,
OUT <a href="./ib_types_h.html#robo119">ib_mr_attr_t</a>* const p_mr_query );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine retrieves the memory region attributed of a
registered memory region. The memory handle could have been
obtained via <a href="#robo602">ci_register_mr</a> or <a href="#robo603">ci_register_pmr</a>.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_mr
[in] Memory handle for which the attributes need to be retrieved.
p_mr_query
[out] Attributes of the memory region associated with memory handle.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The routine completed successfully and attributes returned
are valid.
IB_INVALID_MR_HANDLE
The memory handle is not valid.
IB_INVALID_PARAMETER
One of the input pointers was NULL.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> Invalid handle checks are a mere signature checks in kernel mode.
Drivers in kernel are expected to be good corporate citizens.
In user mode, proper ownership is determined before passing handles
down to kernel to protect from rogue applications.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo602">ci_register_mr</a>, <a href="#robo603">ci_register_pmr</a>
</pre>
</span>
<hr />
<h2><a name="robo600">[Functions]<a name="Verbs2fci5fquery5fmw">
Verbs/ci_query_mw</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_query_mw</strong> -- Query memory window attributes for memory window handle
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_query_mw</strong>) (
IN const ib_mw_handle_t h_mw,
OUT ib_pd_handle_t *ph_pd,
OUT net32_t* const p_rkey,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine retrieves the current R_KEY and protection domain
handle associated with this mw_handle.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_mw
[in] Memory window handle whose attributes are being retrieved.
ph_pd
[out] Protection domain handle associated with this mw_handle
p_rkey
[out] Current R_KEY associated with this mw_handle.The verbs provider
is required to give this in the expected ordering on the wire. When
rkey's are exchanged between remote nodes, no swapping of this data
will be performed.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The query operation completed successfully.
IB_INVALID_MW_HANDLE
mw_handle supplied is an invalid handle
IB_INVALID_PARAMETER
One of the pointers was not valid.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo572">ci_create_mw</a>, <a href="#robo567">ci_bind_mw</a>
</pre>
</span>
<hr />
<h2><a name="robo601">[Functions]<a name="Verbs2fci5fquery5fqp">
Verbs/ci_query_qp</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_query_qp</strong> -- Query the current QP attributes
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_query_qp</strong>) (
IN const ib_qp_handle_t h_qp,
OUT <a href="./ib_types_h.html#robo165">ib_qp_attr_t</a>* const p_qp_attr,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine queries the current attributes for the QP
corresponding to h_qp. The attributes are returned in p_query_attr.
Depending on the current state of the QP, some of the fields in the
attribute structure may not be valid.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_qp
[in] Handle to the QP for which the attributes are being retrieved
p_qp_attr
[out] Pointer to the ib_qp_query_t structure where the current
attributes of the QP is returned.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The values returned in p_qp_attr are valid.
IB_INVALID_QP_HANDLE
The h_qp supplied is not a valid handle.
IB_INVALID_PARAMETER
Parameter p_qp_attr is not valid.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo573">ci_create_qp</a>
</pre>
</span>
<hr />
<h2><a name="robo602">[Functions]<a name="Verbs2fci5fregister5fmr">
Verbs/ci_register_mr</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_register_mr</strong> -- Register a memory region with the HCA.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_register_mr</strong>) (
IN const ib_pd_handle_t h_pd,
IN const <a href="./ib_types_h.html#robo120">ib_mr_create_t</a>* const p_mr_create,
OUT net32_t* const p_lkey,
OUT net32_t* const p_rkey,
OUT ib_mr_handle_t* const ph_mr,
IN boolean_t um_call );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine registers a virtually contiguous region of memory with the
HCA. All memory regions that need to be used by the HCA must be registered
prior to use in data transfer operations. On successful completion
the region handle, lkey are returned. If remote access rights are specified
then the rkey is also returned.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_pd
[in] Handle to the PD on which memory is being registered
p_mr_create
[in] Holds attributes for the region being registered. Look at
<a href="./ib_types_h.html#robo120">ib_mr_create_t</a> for more details.
p_lkey
[out] Local Key Attributes of the registered memory region
p_rkey
[out] Remote key of the registered memory region. The verbs provider
is required to give this in the expected ordering on the wire. When
rkey's are exchanged between remote nodes, no swapping of this data
will be performed.
ph_mr
[out] Handle to the registered memory region. This handle is used when
submitting work requests to refer to this region of memory.
um_call
[in] Boolean indicating whether the registration originated in user-mode.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
Registration with the adapter was successful.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to satisfy request.
IB_INVALID_PARAMETER
One of the input pointers was NULL.
IB_INVALID_PD_HANDLE
Invalid mr_pdhandle
IB_INVALID_PERMISSION
Invalid access rights.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> In addition to registration, the routine also pins memory, so that the
physical page associated with the virtual address does not get swapped
out during the time the HCA is attempting to transfer data to this
address. If the memory is not pinned, this could lead to data-corruption
and unpredictable behavior by the operating environment.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo576">ci_deregister_mr</a>, <a href="#robo599">ci_query_mr</a>, <a href="#robo603">ci_register_pmr</a>, <a href="#robo588">ci_modify_mr</a>,
<a href="#robo604">ci_register_smr</a>
</pre>
</span>
<hr />
<h2><a name="robo603">[Functions]<a name="Verbs2fci5fregister5fpmr">
Verbs/ci_register_pmr</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_register_pmr</strong> -- Register a physical memory region with the HCA.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_register_pmr</strong>) (
IN const ib_pd_handle_t h_pd,
IN const <a href="./ib_types_h.html#robo147">ib_phys_create_t</a>*const p_pmr_create,
IN OUT uint64_t* const p_vaddr,
OUT net32_t* const p_lkey,
OUT net32_t* const p_rkey,
OUT ib_mr_handle_t* const ph_mr,
IN boolean_t um_call );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine registers an array of physical pages as a single virtually
contiguous region with the HCA. All memory regions that need to be used by
the HCA must be registered prior to use in data transfer operations.
On successful completion the region handle, lkey and rkey used for
local and remote access authentication are returned.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_pd
[in] Handle to the PD on which memory is being registered
p_pmr_create
[in] Holds attributes for the region being registered.
p_vaddr
[in/out] On input, references the requested virtual address for the
start of the physical region. On output, references the actual
virtual address assigned to the registered region.
p_lkey
[out] Local key of the registered memory region
p_rkey
[out] Remote key of the registered memory region.The verbs provider
is required to give this in the expected ordering on the wire. When
rkey's are exchanged between remote nodes, no swapping of this data
will be performed.
ph_mr
[out] Handle to the registered memory region. This handle is used when
submitting work requests to refer to this region of memory.
um_call
[in] Boolean indicating whether the registration originated in user-mode.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
Registration with the adapter was successful.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to satisfy request.
IB_INVALID_PARAMETER
Invalid length or address in p_mr_create. Also returned if the page_size
passed is not one of supported page sizes by the HCA.
IB_INVALID_PD_HANDLE
Invalid mr_pdhandle
IB_INVALID_PERMISSION
Invalid access rights.
</pre>
</span><p><strong>PORTABILITY</strong></p>
<span class="PORTABILITY"><pre> Kernel Mode only
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> Remote and Atomic access settings in ib_access_ctrl_t, requires local
write access to be enabled, otherwise IB_INVALID_PERMISSION is returned.
The p_vaddr returned could be different from the vaddr specified in
p_pmr_create. If the requested virtual addr offset in a page does not
match, the channel interface is free to pick and assign a pseudo virtual
address. The address constructed is not a system virtual address, and only
meaningful to the adapter to which this registration is targeted.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo576">ci_deregister_mr</a>, <a href="#robo599">ci_query_mr</a>, <a href="#robo602">ci_register_mr</a>, <a href="#robo588">ci_modify_mr</a>,
<a href="#robo604">ci_register_smr</a>
</pre>
</span>
<hr />
<h2><a name="robo604">[Functions]<a name="Verbs2fci5fregister5fsmr">
Verbs/ci_register_smr</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_register_smr</strong> -- Register a memory region using same physical pages as
an existing memory region.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_register_smr</strong>) (
IN const ib_mr_handle_t h_mr,
IN const ib_pd_handle_t h_pd,
IN const <a href="./ib_types_h.html#robo5">ib_access_t</a> access_ctrl,
IN OUT uint64_t* const p_vaddr,
OUT net32_t* const p_lkey,
OUT net32_t* const p_rkey,
OUT ib_mr_handle_t* const ph_mr,
IN boolean_t um_call );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine registers a new memory region but shares the same set of
physical pages associated with memory handle. For user mode applications
the process *must* be owning memory handle for this call to be successful.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_mr
[in] Handle to memory region whose physical pages are being registered
by this shared registration.
h_pd
[in] Handle to the PD on which memory is being registered
access_ctrl
[in] Memory access restrictions on the registered memory.
p_vaddr
[in/out] On input, references the requested virtual address for the
start of the physical region. On output, references the actual
virtual address assigned to the registered region.
p_lkey
[out] L_KEY for this memory region.
p_rkey
[out] R_KEY for this memory region. This is valid only when remote
access is enabled for this region. The verbs provider
is required to give this in the expected ordering on the wire. When
rkey's are exchanged between remote nodes, no swapping of this data
will be performed.
ph_mr
[out] Handle to the registered memory region. This handle is used when
submitting work requests to refer to this region of memory.
um_call
[in] Boolean indicating whether the registration originated in user-mode.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The call is successful and a new region handle returned is valid.
IB_INVALID_MR_HANDLE
mr_handle is invalid.
IB_INVALID_PD_HANDLE
mr_pdhandle supplied is invalid.
IB_INVALID_PERMISSION
Invalid access rights passed in mr_access.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> ISSUE: how to deal with <a href="#robo576">ci_deregister_mr</a>, <a href="#robo588">ci_modify_mr</a>, <a href="#robo589">ci_modify_pmr</a>
should we treat them as memory windows and fail those if a shared region
was registered?
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo602">ci_register_mr</a>, <a href="#robo603">ci_register_pmr</a>, <a href="#robo588">ci_modify_mr</a>, <a href="#robo589">ci_modify_pmr</a>
</pre>
</span>
<hr />
<h2><a name="robo605">[Functions]<a name="Verbs2fci5fresize5fcq">
Verbs/ci_resize_cq</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_resize_cq</strong> -- Modify the maximum number of entries the CQ could hold.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_resize_cq</strong>) (
IN const ib_cq_handle_t h_cq,
IN OUT uint32_t* const p_size,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine allows the caller to modify the maximum number of entries
the CQ could hold. It is possible to resize the CQ while there are
entries in the CQ, and with outstanding work requests that will generate
completions. If the entries in the CQ are more than the new size which is
being created, an error is returned.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_cq
[in] Completion Queue handle
p_size
[in out] This parameter indicates the requested size of the CQ. On
successful completion, the current size allocated is returned in
this same parameter.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The resize operation was successful.
IB_INVALID_CQ_HANDLE
The CQ handle is invalid.
IB_INSUFFICIENT_RESOURCES
Insufficient resources to complete request.
IB_INVALID_PARAMETER
one of the parameters was NULL.
IB_INVALID_CQ_SIZE
Requested CQ Size is not supported.
IB_OVERFLOW
The CQ has more entries than the resize request. The CQ is not
modified, and old entries still exist.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> If the consumer wishes to resize the CQ smaller than originally created,
it is recommended to retrieve all entries before performing a CQ resize
operation. It is left to the verb implementer on resize operations, to
actually reduce the entries, or leave it as it. The consumer must make no
assumptions on the successful completion, and should only rely on the
size returned in p_size.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo571">ci_create_cq</a>
</pre>
</span>
<hr />
<h2><a name="robo606">[Functions]<a name="Verbs2fci5fum5fclose5fca5ft">
Verbs/ci_um_close_ca_t</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_um_close_ca_t</strong> -- Close user-mode access to adapter via this h_ca
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef void
(*<strong>ci_um_close_ca_t</strong>) (
IN ib_ca_handle_t h_ca,
IN ib_ca_handle_t h_um_ca );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine is called when the client no longer wishes to use HCA
resources obtained via this h_ca. All resources allocated as part
this handle during the <a href="#robo607">ci_um_open_ca</a> are destroyed.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_ca
[in] CA handle returned via the <a href="#robo591">ci_open_ca</a>() call.
h_um_ca
[in] CA handle returned via the <a href="#robo607">ci_um_open_ca</a>() call.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> This funtion does not return a value.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> This call is invoked from the context of a UM application when such an
appliation closes the HCA in user-mode.
Resources allocated during the <a href="#robo607">ci_um_open_ca</a>() are deallocated.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo607">ci_um_open_ca</a>
</pre>
</span>
<hr />
<h2><a name="robo607">[Functions]<a name="Verbs2fci5fum5fopen5fca">
Verbs/ci_um_open_ca</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_um_open_ca</strong> -- Create a CA context for use by user-mode processes.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*ci_um_open_ca_t) (
IN const ib_ca_handle_t h_ca,
IN OUT <a href="#robo608">ci_umv_buf_t</a>* const p_umv_buf,
OUT ib_ca_handle_t* const ph_um_ca );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine is used called on behalf of a user-mode application to
establish a per-CA context in user-mode.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_ca
[in] Handle returned by an earlier call to <a href="#robo591">ci_open_ca</a>()
p_umv_buf
[in/out] Vendor specific parameter to support user mode IO.
ph_um_ca
[out] Handle to pass into ci_um_close_ca call to free any kernel
resources allocated for the user-mode appliation.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The user-mode context information is returned successfully.
IB_INSUFFICIENT_MEMORY
The size of the p_ca_attr buffer, specified through p_size, is
insufficient to store all of the CA attribute information.
IB_INVALID_CA_HANDLE
h_ca is invalid
IB_INVALID_PARAMETER
The p_umv_buf parameters are insufficient to complete the request.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo597">ci_query_ca</a>, <a href="#robo587">ci_modify_ca</a>, <a href="#robo568">ci_close_ca</a>
</pre>
</span>
<hr />
<h2><a name="robo608">[Structures]<a name="Verbs2fci5fumv5fbuf5ft">
Verbs/ci_umv_buf_t</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_strutures.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_umv_buf_t</strong> -- Vendor specific structure to facilitate user mode IO
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This structure is provided to assist the vendor specific user mode
library to exchange information with its kernel mode driver. The
user mode InfiniBand(tm) Access Layer will call the vendor specific
module before a call is made to the kernel mode driver. The kernel mode
driver is expected to know the format and data in the p_inout_buf,
and copy any necessary data that must be handed to the user mode
vendor library.
</pre>
</span><p><strong>PURPOSE</strong></p>
<span class="PURPOSE"><pre> command
A command code that is understood by the vendor specific kernel
mode driver.
p_inout_buf
The user mode component of the vendor specific library allocates
this memory and passes information in this buffer. vendor is expected
to set both the input and output buffer sizes appropriately.
This information is required since the kernel mode proxy that passes
this buffer to the kernel mode vendor specific library will copy the
content of this buffer to a kernel mode buffer. The kernel mode
vendor specific driver would copy the data that needs to be returned
to the user mode component, and set the output size appropriately
so that the proxy can now copy the data back to user mode buffer.
In the Infiniband Access Layer, it is important to know the
usage of umv_buf and whether the contents of the p_inout_buf
can have embedded user-mode pointers. When invoked from an
arbitrary thread context, Vendor driver can NOT access user-mode
pointers of a user-process.
input_size
Size of the input buffer, must be set by the user mode vendor
specific library.
output_size
Size of the output buffer. Must be set by the user mode component
to specify the maximum size of the data expected from its kernel
mode driver. The kernel mode driver would set the size to the exact
size that needs to be returned to its user mode counterpart.
status
Indicates the status of the operation from the kernel mode vendor
specific driver. The caller is supposed to initialize it appropriately
to identify if an operation succeded, or failed. For e.g. when
the user mode library is called after a resource creation, the user
mode vendor specific code must be able to identify if there is
post processing required, or if any resource allocation failed.
</pre>
</span><p><strong>SOURCE</strong></p>
<span class="SOURCE"><pre>typedef struct _umv_buf
{
uint32_t command;
uint32_t status;
uint32_t input_size;
uint32_t output_size;
void* __ptr64 p_inout_buf;
} <strong>ci_umv_buf_t</strong>;
</pre>
</span>
<hr />
<h2><a name="robo609">[Functions]<a name="Verbs2fci5fvendor5fcall">
Verbs/ci_vendor_call</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ci_vendor_call</strong>
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> Performs a vendor specific CA interface function call.
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>typedef <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
(*<strong>ci_vendor_call</strong>)(
IN const ib_ca_handle_t h_ca,
IN const void* __ptr64* const handle_array OPTIONAL,
IN uint32_t num_handles,
IN <a href="./ib_types_h.html#robo26">ib_ci_op_t</a>* const p_ci_op,
IN OUT <a href="#robo608">ci_umv_buf_t</a> *p_umv_buf OPTIONAL );
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> h_ca
[in] A handle to an opened CA.
handle_array
[in] This parameter references an array containing handles of
existing CA resources. This array should contain all of the
handles specified in the vendor specific data provided with this
call. All handles specified through this array are validated by
the verbs provider driver to ensure that the number and type of
handles are correct for the requested operation.
num_handles
[in] The number of the handles in handle array. This count is
verified by the access layer.
p_ci_op
[in] A reference to the vendor specific CA interface data
structure containing the operation parameters.
p_umv_buf
[in out] Vendor specific parameter to support user mode IO.
RETURN VALUES
IB_SUCCESS
The operation was successful.
IB_INVALID_CA_HANDLE
The CA handle was invalid.
IB_INVALID_PARAMETER
A reference to the vendor specific data was not provided.
IB_INVALID_HANDLE
A handle specified in the handle array was invalid.
IB_INSUFFICIENT_MEMORY
There was insufficient memory to perform the operation.
IB_ERROR
An error occurred while processing the command. Additional
error information is provided in the p_ci_op status field.
</pre>
</span><p><strong>NOTES</strong></p>
<span class="NOTES"><pre> This routine performs a vendor specific CA interface function call.
The p_ci_op structure provides a means to pass vendor specific data to
the verbs provider driver. If the vendor specific data contains handles,
the client should provide the optional handle array that lists all of
all of the handles specified in the vendor specific data. The handles
in the handle array are restricted to the following types: ib_ca_handle_t,
ib_pd_handle_t, ib_cq_handle_t, ib_av_handle_t, ib_qp_handle_t,
ib_mr_handle_t, or ib_mw_handle_t
The contents of the handle array are verified by the
access layer and the verbs provider driver.
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo591">ci_open_ca</a>, <a href="#robo564">ci_allocate_pd</a>, <a href="#robo570">ci_create_av</a>, <a href="#robo571">ci_create_cq</a>,
<a href="#robo573">ci_create_qp</a>, <a href="#robo602">ci_register_mr</a>, <a href="#robo603">ci_register_pmr</a>,
<a href="#robo604">ci_register_smr</a>, <a href="#robo572">ci_create_mw</a>, <a href="./ib_types_h.html#robo26">ib_ci_op_t</a>
</pre>
</span>
<hr />
<h2><a name="robo611">[Functions]<a name="Verbs2fib5fderegister5fca">
Verbs/ib_deregister_ca</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ib_deregister_ca</strong> -- Inform the IB Access Layer that this HCA is no longer available
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>AL_EXPORT <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
<strong>ib_deregister_ca</strong> (
IN const net64_t ca_guid );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine is called by the HCA driver when this HCA would no longer be
available for services. The access layer is expected to return all resources
back to the HCA driver, and perform a <a href="#robo568">ci_close_ca</a> on this interface.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> ca_guid
[in] GUID of the HCA that is being removed.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The deregistration is successful.
IB_NOT_FOUND
No HCA with the specified GUID is registered.
IB_BUSY
The HCA is still in use and cannot be released.
</pre>
</span><p><strong>PORTABILITY</strong></p>
<span class="PORTABILITY"><pre> Kernel Mode only
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo613">ib_register_ca</a>, <a href="#robo584">ci_interface_t</a>
</pre>
</span>
<hr />
<h2><a name="robo613">[Functions]<a name="Verbs2fib5fregister5fca">
Verbs/ib_register_ca</a></h2>
<p>[<a href="#robo_top_of_doc">top</a>][<a href="#robo1">parent</a>][<a href="./robo_functions.html#top">index</a>]</p>
<p><strong>NAME</strong></p>
<span class="NAME"><pre> <strong>ib_register_ca</strong> -- Inform the IB Access Layer about a new HCA
</pre>
</span><p><strong>SYNOPSIS</strong></p>
<span class="SYNOPSIS"><pre>AL_EXPORT <a href="./ib_types_h.html#robo9">ib_api_status_t</a>
<strong>ib_register_ca</strong> (
IN const <a href="#robo584">ci_interface_t</a> *p_ci );
</pre>
</span><p><strong>DESCRIPTION</strong></p>
<span class="DESCRIPTION"><pre> This routine is called by a HCA kernel mode driver to inform the
IB Access Layer about a new HCA that is ready for use. It is expected
that the Access Layer could immediatly turn around and call for services
even before the call returns back the HCA driver code. The HCA driver
must initialize all resources and be ready to service any calls before adding
its services to the IB Access Layer.
</pre>
</span><p><strong>PARAMETERS</strong></p>
<span class="PARAMETERS"><pre> p_ci
[in] Pointer to the <a href="#robo584">ci_interface_t</a> structure that has the function
vector to support verbs functionality.
</pre>
</span><p><strong>RETURN VALUE</strong></p>
<span class="RETURN_VALUE"><pre> IB_SUCCESS
The registration is successful.
IB_INVALID_PARAMETER
A reference to the CI interface structure was not provided.
IB_INSUFFICIENT_RESOURCES
Insufficient memory to satisfy resource requirements.
IB_DUPLICATE_CA
HCA GUID is already registered with the IB Access Layer
</pre>
</span><p><strong>PORTABILITY</strong></p>
<span class="PORTABILITY"><pre> Kernel Mode only
</pre>
</span><p><strong>SEE ALSO</strong></p>
<span class="SEE_ALSO"><pre> <a href="#robo611">ib_deregister_ca</a>, <a href="#robo584">ci_interface_t</a>
</pre>
</span>
</body>
</html>