/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
*/
/*
* Hermon Fibre Channel over IB routines
*
* Implements all the routines necessary for setting up, using, and
* (later) tearing down all the FCoIB state.
*/
/*
* hermon_fcoib_enable()
* Context: user or kernel context
*/
static int
{
int status;
port--; /* passed in as 1 or 2, used as 0 or 1 */
/* Configure FCoIB on the port */
#if 1
#else
#endif
if (status != HERMON_CMD_SUCCESS) {
return (DDI_FAILURE);
}
return (DDI_SUCCESS);
}
/*
* hermon_fcoib_set_id()
* Context: user or kernel context
*/
int
{
int status;
int offset;
port--; /* passed in as 1 or 2, used as 0 or 1 */
return (DDI_FAILURE);
}
}
if (status != HERMON_CMD_SUCCESS) {
return (DDI_FAILURE);
}
return (DDI_SUCCESS);
}
/*
* hermon_fcoib_get_id_idx()
* Context: user or kernel context
*/
int
{
int idx;
port--; /* passed in as 1 or 2, used as 0 or 1 */
idx = -1;
return (idx);
}
/*
* hermon_fcoib_get_exch_base()
* Context: user or kernel context
*/
int
{
int exch_base_off;
port--; /* passed in as 1 or 2, used as 0 or 1 */
exch_base_off = -1;
return (exch_base_off);
}
/*
* hermon_fcoib_qpnum_from_fexch()
* Context: user, kernel, or interrupt context
*/
int
{
}
/*
* hermon_fcoib_qpnum_from_fexch()
* Context: user, kernel, or interrupt context
*/
{
port--; /* passed in as 1 or 2, used as 0 or 1 */
return (qpnum);
}
/*
* hermon_fcoib_qpn_to_mkey
* Context: user or kernel context
*/
{
int i;
for (i = 0; i < fcoib->hfc_nports; i++) {
}
}
/*
* hermon_fcoib_fexch_relative_qpn()
* Context: user or kernel context
*/
{
port--;
return (qp_indx);
}
/*
* hermon_fcoib_fexch_mkey_init()
* Context: user or kernel context
*/
int
{
int status;
port--;
return (IBT_INVALID_PARAM);
return (status);
}
/*
* hermon_fcoib_fexch_mkey_fini()
* Context: user or kernel context
*/
int
{
int status;
goto found;
}
return (IBT_INVALID_PARAM);
/* qp_indx relative to FEXCH base */
return (status);
}
/*
* hermon_fcoib_query_fc()
* Context: user or kernel context
*/
void
{
int status;
sizeof (query_fc), HERMON_CMD_NOSLEEP_SPIN);
if (status == HERMON_CMD_SUCCESS) {
} else
}
/*
* hermon_fcoib_init()
* Context: Only called from attach() path context
*/
int
{
int i;
/* used for fast checking for FCoIB during cqe_consume */
return (DDI_SUCCESS);
/* use a ROUND value that works on both 32 and 64-bit kernels */
return (DDI_FAILURE);
}
/*
* Only reserve MTTs for the Primary MPTs (first half of the
* range for each port).
*/
return (DDI_FAILURE);
}
return (DDI_FAILURE);
}
return (DDI_FAILURE);
}
for (i = 0; i < numports; i++) {
fcoib->hfc_port_enabled[i] = 0;
/* "/ 2" is for Secondary MKEYs never used on Client side */
/* init FEXCH QP rsrc pool */
/* init RFCI QP rsrc pool */
}
return (DDI_SUCCESS);
}
/*
* hermon_fcoib_fini()
*/
void
{
int i;
return;
for (i = 0; i < numports; i++) {
if (fcoib->hfc_rfci_vmemp[i])
if (fcoib->hfc_fexch_vmemp[i])
if (fcoib->hfc_n_port_ids[i])
/* XXX --- should we issue HERMON_HW_FC_CONF_BASIC disable? */
fcoib->hfc_port_enabled[i] = 0;
}
if (fcoib->hfc_rfci_rsrc)
if (fcoib->hfc_fexch_rsrc)
if (fcoib->hfc_mpt_rsrc)
if (fcoib->hfc_mtt_rsrc)
}