2 .\" Copyright (c) 1996, Sun Microsystems, Inc. All Rights Reserved
3 .\" 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.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" 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]
6 .TH CSX_GETFIRSTTUPLE 9F "Dec 20, 1996"
8 csx_GetFirstTuple, csx_GetNextTuple \- return Card Information Structure tuple
12 #include <sys/pccard.h>
16 \fBint32_t\fR \fBcsx_GetFirstTuple\fR(\fBclient_handle_t\fR \fIch\fR, \fBtuple_t *\fR\fItu\fR);
21 \fBint32_t\fR \fBcsx_GetNextTuple\fR(\fBclient_handle_t\fR \fIch\fR, \fBtuple_t *\fR\fItu\fR);
27 Solaris \fBDDI \fRSpecific (Solaris \fBDDI) \fR
35 Client handle returned from \fBcsx_RegisterClient\fR(9F).
44 Pointer to a \fBtuple_t\fR structure.
50 The functions \fBcsx_GetFirstTuple()\fR and \fBcsx_GetNextTuple()\fR return the
51 first and next tuple, respectively, of the specified type in the Card
52 Information Structure (CIS) for the specified socket.
56 The structure members of \fBtuple_t\fR are:
60 uint32_t Socket; /* socket number */
61 uint32_t Attributes; /* Attributes */
62 cisdata_t DesiredTuple; /* tuple to search for or flags */
63 cisdata_t TupleCode; /* tuple type code */
64 cisdata_t TupleLink; /* tuple data body size */
70 The fields are defined as follows:
77 Not used in Solaris, but for portability with other Card Services
78 implementations, it should be set to the logical socket number.
84 \fB\fBAttributes\fR\fR
87 This field is bit-mapped. The following bits are defined:
91 \fBTUPLE_RETURN_LINK\fR
95 Return link tuples if set. The following are link tuples and will only be
96 returned by this function if the \fBTUPLE_RETURN_LINK\fR bit in the
97 \fBAttributes\fR field is set:
101 CISTPL_NULL CISTPL_LONGLINK_MFC
102 CISTPL_LONGLINK_A CISTPL_LINKTARGET
103 CISTPL_LONGLINK_C CISTPL_NO_LINK
104 CISTPL_LONGLINK_CB CISTPL_END
113 \fBTUPLE_RETURN_IGNORED_TUPLES\fR
117 Return ignored tuples if set. Ignored tuples will be returned by this function
118 if the \fBTUPLE_RETURN_IGNORED_TUPLES\fR bit in the \fBAttributes\fR field is
119 set, see \fBtuple\fR(9S) for more information. The \fBCIS \fRis parsed from the
120 location setup by the previous \fBcsx_GetFirstTuple()\fR or
121 \fBcsx_GetNextTuple()\fR request.
129 \fB\fBDesiredTuple\fR\fR
132 This field is the tuple value desired. If it is \fBRETURN_FIRST_TUPLE,\fR the
133 very first tuple of the \fBCIS \fRis returned (if it exists). If this field is
134 set to \fBRETURN_NEXT_TUPLE,\fR the very next tuple of the \fBCIS \fRis
135 returned (if it exists). If the \fBDesiredTuple\fR field is any other value on
136 entry, the \fBCIS \fRis searched in an attempt to locate a tuple which matches.
142 \fB\fBTupleCode,TupleLink\fR\fR
145 These fields are the values returned from the tuple found. If there are no
146 tuples on the card, \fBCS_NO_MORE_ITEMS\fR is returned.
151 Since the \fBcsx_GetFirstTuple()\fR, \fBcsx_GetNextTuple()\fR, and
152 \fBcsx_GetTupleData\fR(9F) functions all share the same \fBtuple_t\fR
153 structure, some fields in the \fBtuple_t\fR structure are unused or reserved
154 when calling this function and these fields must not be initialized by the
160 \fB\fBCS_SUCCESS\fR\fR
163 Successful operation.
169 \fB\fBCS_BAD_HANDLE\fR\fR
172 Client handle is invalid.
178 \fB\fBCS_NO_CARD\fR\fR
181 No \fBPC \fRCard in socket.
187 \fB\fBCS_NO_CIS\fR\fR
190 No Card Information Structure (CIS) on \fBPC \fRcard.
196 \fB\fBCS_NO_MORE_ITEMS\fR\fR
199 Desired tuple not found.
205 \fB\fBCS_UNSUPPORTED_FUNCTION\fR\fR
208 No \fBPCMCIA \fRhardware installed.
214 These functions may be called from user or kernel context.
218 \fBcsx_GetTupleData\fR(9F), \fBcsx_ParseTuple\fR(9F),
219 \fBcsx_RegisterClient\fR(9F), \fBcsx_ValidateCIS\fR(9F), \fBtuple\fR(9S)
222 \fIPC Card \fR\fI95Standard,\fR PCMCIA/JEIDA