ibtl_cq.c revision 7c478bd95313f5f23a4c958a745db2134aa03244
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (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
*/
/*
* Copyright 2004 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
/*
* These routines implement (most of) the verbs related to
* Completion Queues.
*/
/*
* Globals
*/
static char ibtf_cq[] = "ibtl_cq";
/*
* This file contains code for the TI CQ calls
*/
/*
* ibt_alloc_cq_sched() - Reserve CQ scheduling class resources
*
* chan - IBT Channel Handle.
* load - Expected CQ load in class, 0 = unspecified
* sched_hdl_p - Returned scheduling handle.
*/
{
/* Validate and Convert the IBT CQ priority */
return (IBT_CQ_INVALID_PRIORITY);
}
/*
* Do we need to check for valid range for load ? What's the valid
* range?
*/
}
/*
* ibt_free_cq_sched() - Free CQ scheduling class resources
*
* chan - IBT Channel Handle.
* sched_hdl - Scheduling handle returned from ibt_alloc_cq_sched.
* load - CQ load being removed.
*/
{
/*
* Function not fully implemented should get handler ID from
* sched_hdl.
*/
}
/*
*
* ibt_alloc_cq() - Allocate a completion queue
*/
{
/*
* Set the following values before creating CI CQ, to avoid race
* conditions on async callback.
*/
if (status != IBT_SUCCESS) {
"CI CQ handle allocation failed: status = %d", status);
return (status);
}
/* We may want additional CQ threads now. */
}
/* Update the cq resource count */
return (IBT_SUCCESS);
}
/*
* ibt_free_cq() - Free a completion queue
*
*/
{
if (status != IBT_SUCCESS) {
"CI CQ handle de-allocation failed: status = %d", status);
return (status);
}
/* mutex_destroy(&ibt_cq->cq_mutex); */
/* Update the cq resource count */
return (status);
}
/*
* ibt_query_cq() - Returns the size of the cq
*/
{
}
/*
* ibt_resize_cq() - Change the size of a cq.
*/
{
}
/*
* ibt_poll_cq()
* Poll the specified CQ for a work request (WR) completion. If a CQ
* contains a completed WR, the completed WR at the head of the CQ is
* returned.
*
* ibt_cq The CQ handle.
*
* work_completions An array of work completions.
*
* num_wc Size of the Work completion array. The
* requested number of completions.
*
* num_polled The actual number of completions returned.
*
*/
{
}
/*
* ibt_set_cq_private - Sets the private data on a given CQ
*
* ibt_cq The ibt_cq_hdl_t of the allocated CQ.
* clnt_private The client private data.
*/
void
{
}
/*
* ibt_get_cq_private - Retrieves the private data for a given CQ
*
* ibt_cq The ibt_cq_hdl_t of the allocated CQ.
*/
void *
{
return (ibt_cq->cq_clnt_private);
}