1 '\" te
   2 .\"  Copyright (c) 2000, Sun Microsystems, Inc.
   3 .\"  All Rights Reserved
   4 .\" 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.
   5 .\" 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.
   6 .\" 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]
   7 .TH CSX_PARSE_CISTPL_BYTEORDER 9F "Dec 20, 1996"
   8 .SH NAME
   9 csx_Parse_CISTPL_BYTEORDER \- parse the Byte Order tuple
  10 .SH SYNOPSIS
  11 .LP
  12 .nf
  13 #include <sys/pccard.h>
  14 
  15 
  16 
  17 \fBint32_t\fR \fBcsx_Parse_CISTPL_BYTEORDER\fR(\fBclient_handle_t\fR \fIch\fR, \fBtuple_t *\fR\fItu\fR,
  18      \fBcistpl_byteorder_t *\fR\fIcbo\fR);
  19 .fi
  20 
  21 .SH INTERFACE LEVEL
  22 .sp
  23 .LP
  24 Solaris \fBDDI \fRSpecific (Solaris \fBDDI) \fR
  25 .SH PARAMETERS
  26 .sp
  27 .ne 2
  28 .na
  29 \fB\fIch\fR \fR
  30 .ad
  31 .RS 8n
  32 Client handle returned from \fBcsx_RegisterClient\fR(9F).
  33 .RE
  34 
  35 .sp
  36 .ne 2
  37 .na
  38 \fB\fItu\fR \fR
  39 .ad
  40 .RS 8n
  41 Pointer to a \fBtuple_t\fR structure (see \fBtuple\fR(9S)) returned by a call
  42 to \fBcsx_GetFirstTuple\fR(9F) or \fBcsx_GetNextTuple\fR(9F).
  43 .RE
  44 
  45 .sp
  46 .ne 2
  47 .na
  48 \fB\fIcbo\fR \fR
  49 .ad
  50 .RS 8n
  51 Pointer to a \fBcistpl_byteorder_t\fR structure which contains the parsed
  52 \fBCISTPL_BYTEORDER\fR tuple information upon return from this function.
  53 .RE
  54 
  55 .SH DESCRIPTION
  56 .sp
  57 .LP
  58 This function parses the Byte Order tuple, \fBCISTPL_BYTEORDER\fR, into a form
  59 usable by \fBPC \fRCard drivers.
  60 .sp
  61 .LP
  62 The \fBCISTPL_BYTEORDER\fR tuple shall only appear in a partition tuple set for
  63 a memory-like partition. It specifies two parameters: the order for multi-byte
  64 data, and the order in which bytes map into words for 16-bit cards.
  65 .SH STRUCTURE MEMBERS
  66 .sp
  67 .LP
  68 The structure members of \fBcistpl_byteorder_t\fR are:
  69 .sp
  70 .in +2
  71 .nf
  72 uint32_t     order;     /* byte order code */
  73 uint32_t     map;       /* byte mapping code */
  74 .fi
  75 .in -2
  76 
  77 .sp
  78 .LP
  79 The fields are defined as follows:
  80 .sp
  81 .ne 2
  82 .na
  83 \fB\fBorder\fR \fR
  84 .ad
  85 .RS 10n
  86 This field specifies the byte order for multi-byte numeric data.
  87 .sp
  88 .ne 2
  89 .na
  90 \fBTPLBYTEORD_LOW\fR
  91 .ad
  92 .RS 18n
  93 Little endian order
  94 .RE
  95 
  96 .sp
  97 .ne 2
  98 .na
  99 \fBTPLBYTEORD_VS\fR
 100 .ad
 101 .RS 18n
 102 Vendor specific
 103 .RE
 104 
 105 .RE
 106 
 107 .sp
 108 .ne 2
 109 .na
 110 \fB\fBmap\fR \fR
 111 .ad
 112 .RS 10n
 113 This field specifies the byte mapping for 16-bit or wider cards.
 114 .sp
 115 .ne 2
 116 .na
 117 \fBTPLBYTEMAP_LOW\fR
 118 .ad
 119 .RS 19n
 120 Byte zero is least significant byte
 121 .RE
 122 
 123 .sp
 124 .ne 2
 125 .na
 126 \fBTPLBYTEMAP_HIGH\fR
 127 .ad
 128 .RS 19n
 129 Byte zero is most significant byte
 130 .RE
 131 
 132 .sp
 133 .ne 2
 134 .na
 135 \fBTPLBYTEMAP_VS\fR
 136 .ad
 137 .RS 19n
 138 Vendor specific mapping
 139 .RE
 140 
 141 .RE
 142 
 143 .SH RETURN VALUES
 144 .sp
 145 .ne 2
 146 .na
 147 \fB\fBCS_SUCCESS\fR \fR
 148 .ad
 149 .RS 28n
 150 Successful operation.
 151 .RE
 152 
 153 .sp
 154 .ne 2
 155 .na
 156 \fB\fBCS_BAD_HANDLE\fR \fR
 157 .ad
 158 .RS 28n
 159 Client handle is invalid.
 160 .RE
 161 
 162 .sp
 163 .ne 2
 164 .na
 165 \fB\fBCS_UNKNOWN_TUPLE\fR \fR
 166 .ad
 167 .RS 28n
 168 Parser does not know how to parse tuple.
 169 .RE
 170 
 171 .sp
 172 .ne 2
 173 .na
 174 \fB\fBCS_NO_CARD\fR \fR
 175 .ad
 176 .RS 28n
 177 No \fBPC \fRCard in socket.
 178 .RE
 179 
 180 .sp
 181 .ne 2
 182 .na
 183 \fB\fBCS_NO_CIS\fR \fR
 184 .ad
 185 .RS 28n
 186 No Card Information Structure (CIS) \fBPC \fRCard.
 187 .RE
 188 
 189 .sp
 190 .ne 2
 191 .na
 192 \fB\fBCS_UNSUPPORTED_FUNCTION\fR \fR
 193 .ad
 194 .RS 28n
 195 No \fBPCMCIA \fRhardware installed.
 196 .RE
 197 
 198 .SH CONTEXT
 199 .sp
 200 .LP
 201 This function may be called from user or kernel context.
 202 .SH SEE ALSO
 203 .sp
 204 .LP
 205 \fBcsx_GetFirstTuple\fR(9F), \fBcsx_GetTupleData\fR(9F),
 206 \fBcsx_RegisterClient\fR(9F), \fBcsx_ValidateCIS\fR(9F), \fBtuple\fR(9S)
 207 .sp
 208 .LP
 209 \fIPC Card 95 Standard, PCMCIA/JEIDA\fR