libefi: import efichar.c for ucs2 support
[unleashed.git] / include / sys / timod.h
blob4c9d5aad37a1e26246626aedc69b76976e359ae6
1 /*
2 * CDDL HEADER START
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License, Version 1.0 only
6 * (the "License"). You may not use this file except in compliance
7 * with the License.
9 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 * or http://www.opensolaris.org/os/licensing.
11 * See the License for the specific language governing permissions
12 * and limitations under the License.
14 * When distributing Covered Code, include this CDDL HEADER in each
15 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 * If applicable, add the following below this CDDL HEADER, with the
17 * fields enclosed by brackets "[]" replaced with your own identifying
18 * information: Portions Copyright [yyyy] [name of copyright owner]
20 * CDDL HEADER END
23 * Copyright 1998 Sun Microsystems, Inc. All rights reserved.
24 * Use is subject to license terms.
27 /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
28 /* All Rights Reserved */
30 #ifndef _SYS_TIMOD_H
31 #define _SYS_TIMOD_H
33 #include <sys/types.h>
34 #include <sys/stream.h>
36 #ifdef __cplusplus
37 extern "C" {
38 #endif
40 /* Timod ioctls */
41 #define TIMOD ('T'<<8)
42 #define TI_GETINFO (TIMOD|140)
43 #define TI_OPTMGMT (TIMOD|141)
44 #define TI_BIND (TIMOD|142)
45 #define TI_UNBIND (TIMOD|143)
46 #define TI_GETMYNAME (TIMOD|144)
47 #define TI_GETPEERNAME (TIMOD|145)
48 #define TI_SETMYNAME (TIMOD|146)
49 #define TI_SETPEERNAME (TIMOD|147)
50 #define TI_SYNC (TIMOD|148)
51 #define TI_GETADDRS (TIMOD|149)
52 #define TI_CAPABILITY (TIMOD|150)
55 * There are two ioctls to get information from the kernel. One is TI_SYNC
56 * and it should be only used to exchange information between the library and
57 * timod. It should not request any TPI information. The second ioctl is
58 * TI_CAPABILITY which is extensible ioctl for getting all the information from
59 * transport provider.
62 /* sent with TI_SYNC */
63 struct ti_sync_req {
64 uint32_t tsr_flags;
65 /* can grow at the end */
69 * For use with tsr_flags
70 * TSRF_INFO_REQ is obsolete and shouldn't be used in new code. Use
71 * TI_CAPABILITY ioctl instead.
73 #define TSRF_INFO_REQ 0x1 /* get info about transport endpoint */
74 #define TSRF_IS_EXP_IN_RCVBUF 0x2 /* look for exp ind in rcvbuf */
75 #define TSRF_QLEN_REQ 0x4 /* get qlen from timod */
77 /* returned by TI_SYNC */
78 struct ti_sync_ack {
80 * - initial part derived from and matches T_info_ack
81 * - returned when TSRF_INFO_REQ is set on request
83 t_scalar_t PRIM_type;
84 t_scalar_t TSDU_size;
85 t_scalar_t ETSDU_size;
86 t_scalar_t CDATA_size;
87 t_scalar_t DDATA_size;
88 t_scalar_t ADDR_size;
89 t_scalar_t OPT_size;
90 t_scalar_t TIDU_size;
91 t_scalar_t SERV_type;
92 t_scalar_t CURRENT_state;
93 t_scalar_t PROVIDER_flag;
96 * endpoint qlen backlog, returned when TSRF_INFO_REQ is set on request
98 t_uscalar_t tsa_qlen;
101 * misc flags info - bits set based on what is requested.
103 uint32_t tsa_flags;
104 /* can grow at the end */
108 * Flag bits for use with tsa_flags
112 * TSAF_EXP_QUEUED:
113 * set/clear significant when TSRF_IS_EXP_IN_RCVBUF is set on request
115 #define TSAF_EXP_QUEUED 0x1
117 #ifdef __cplusplus
119 #endif
121 #endif /* _SYS_TIMOD_H */