kernel: Sync ACPICA with Intel's version 20140424.
[dragonfly.git] / sys / netproto / atm / atm_var.h
1 /*
2  *
3  * ===================================
4  * HARP  |  Host ATM Research Platform
5  * ===================================
6  *
7  *
8  * This Host ATM Research Platform ("HARP") file (the "Software") is
9  * made available by Network Computing Services, Inc. ("NetworkCS")
10  * "AS IS".  NetworkCS does not provide maintenance, improvements or
11  * support of any kind.
12  *
13  * NETWORKCS MAKES NO WARRANTIES OR REPRESENTATIONS, EXPRESS OR IMPLIED,
14  * INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF MERCHANTABILITY
15  * AND FITNESS FOR A PARTICULAR PURPOSE, AS TO ANY ELEMENT OF THE
16  * SOFTWARE OR ANY SUPPORT PROVIDED IN CONNECTION WITH THIS SOFTWARE.
17  * In no event shall NetworkCS be responsible for any damages, including
18  * but not limited to consequential damages, arising from or relating to
19  * any use of the Software or related support.
20  *
21  * Copyright 1994-1998 Network Computing Services, Inc.
22  *
23  * Copies of this Software may be made, however, the above copyright
24  * notice must be reproduced on all copies.
25  *
26  *      @(#) $FreeBSD: src/sys/netatm/atm_var.h,v 1.2 1999/08/28 00:48:39 peter Exp $
27  *      @(#) $DragonFly: src/sys/netproto/atm/atm_var.h,v 1.10 2005/11/28 17:13:46 dillon Exp $
28  *
29  */
30
31 /*
32  * Core ATM Services
33  * -----------------
34  *
35  * ATM system variables
36  *
37  */
38
39 #ifndef _NETATM_ATM_VAR_H
40 #define _NETATM_ATM_VAR_H
41
42
43 #ifdef ATM_KERNEL
44 /*
45  * Global variable declarations
46  */
47         /* atm_aal5.c */
48 extern struct pr_usrreqs        atm_aal5_usrreqs;
49
50         /* atm_proto.c */
51 extern struct domain    atmdomain;
52
53         /* atm_subr.c */
54 extern struct atm_pif   *atm_interface_head;
55 extern struct atm_ncm   *atm_netconv_head;
56 extern Atm_endpoint     *atm_endpoints[];
57 extern struct sp_info   *atm_pool_head;
58 extern struct stackq_entry      *atm_stackq_head;
59 extern struct stackq_entry      *atm_stackq_tail;
60 extern struct ifqueue   atm_intrq;
61 extern struct atm_sock_stat     atm_sock_stat;
62 extern int              atm_init;
63 extern int              atm_version;
64 extern int              atm_debug;
65 extern struct timeval   atm_debugtime;
66 extern int              atm_dev_print;
67 extern int              atm_print_data;
68 extern struct sp_info   atm_attributes_pool;
69
70         /* atm_usrreq.c */
71 extern struct pr_usrreqs        atm_dgram_usrreqs;
72
73 struct lwkt_serialize;
74 union netmsg;
75
76 /*
77  * Global function declarations
78  */
79         /* atm_aal5.c */
80 void            atm_aal5_ctloutput (union netmsg *);
81 void            atm_aal5_init (void);
82
83         /* atm_cm.c */
84 int             atm_cm_connect (Atm_endpoint *, void *, Atm_attributes *,
85                         Atm_connection **);
86 int             atm_cm_listen (Atm_endpoint *, void *, Atm_attributes *,
87                         Atm_connection **);
88 int             atm_cm_addllc (Atm_endpoint *, void *, struct attr_llc *,
89                         Atm_connection *, Atm_connection **);
90 int             atm_cm_addparty (Atm_connection *, int,
91                         struct t_atm_sap *);
92 int             atm_cm_dropparty (Atm_connection *, int,
93                         struct t_atm_cause *);
94 int             atm_cm_release (Atm_connection *, struct t_atm_cause *);
95 int             atm_cm_abort (Atm_connvc *, struct t_atm_cause *);
96 int             atm_cm_incoming (struct vccb *, Atm_attributes *);
97 void            atm_cm_connected (Atm_connvc *);
98 void            atm_cm_cleared (Atm_connvc *);
99 Atm_connection *atm_cm_match (Atm_attributes *, Atm_connection *);
100 int             atm_cm_cpcs_ctl (int, Atm_connection *, void *);
101 int             atm_cm_cpcs_data (Atm_connection *, KBuffer *);
102 int             atm_cm_saal_ctl (int, Atm_connection *, void *);
103 int             atm_cm_saal_data (Atm_connection *, KBuffer *);
104 int             atm_cm_sscop_ctl (int, Atm_connection *, void *, void *);
105 int             atm_cm_sscop_data (Atm_connection *, KBuffer *);
106 int             atm_endpoint_register (Atm_endpoint *);
107 int             atm_endpoint_deregister (Atm_endpoint *);
108
109         /* atm_device.c */
110 int             atm_dev_inst (struct stack_defn **, Atm_connvc *);
111 void            atm_dev_lower (int, void *, int, int);
112 void *          atm_dev_alloc (u_int, u_int, u_int);
113 void            atm_dev_free (volatile void *);
114 KBuffer *       atm_dev_compress (KBuffer *);
115 Cmn_vcc *       atm_dev_vcc_find (Cmn_unit *, u_int, u_int, u_int);
116 void            atm_dev_pdu_print (Cmn_unit *, Cmn_vcc *, KBuffer *,
117                         char *);
118
119         /* atm_if.c */
120 int             atm_physif_register (Cmn_unit *, char *,
121                         struct stack_defn *);
122 int             atm_physif_deregister (Cmn_unit *);
123 void            atm_physif_freenifs (struct atm_pif *);
124 int             atm_netconv_register (struct atm_ncm *);
125 int             atm_netconv_deregister (struct atm_ncm *);
126 int             atm_nif_attach (struct atm_nif *, struct lwkt_serialize *);
127 void            atm_nif_detach (struct atm_nif *);
128 int             atm_nif_setaddr (struct atm_nif *, struct ifaddr *);
129 int             atm_ifoutput (struct ifnet *, KBuffer *,
130                         struct sockaddr *, struct rtentry *);
131 struct atm_pif *
132                 atm_pifname (char *);
133 struct atm_nif *
134                 atm_nifname (char *);
135
136         /* atm_signal.c */
137 int             atm_sigmgr_register (struct sigmgr *);
138 int             atm_sigmgr_deregister (struct sigmgr *);
139 int             atm_sigmgr_attach (struct atm_pif *, u_char);
140 int             atm_sigmgr_detach (struct atm_pif *);
141 int             atm_stack_register (struct stack_defn *);
142 int             atm_stack_deregister (struct stack_defn *);
143 int             atm_create_stack (Atm_connvc *, struct stack_list *,
144                         void (*)(int, void *, int, int) );
145
146         /* atm_socket.c */
147 int             atm_sock_attach (struct socket *, u_long, u_long,
148                         struct rlimit *);
149 int             atm_sock_detach (struct socket *);
150 int             atm_sock_bind (struct socket *, struct sockaddr *);
151 int             atm_sock_listen (struct socket *, Atm_endpoint *);
152 int             atm_sock_connect (struct socket *, struct sockaddr *,
153                         Atm_endpoint *);
154 int             atm_sock_disconnect (struct socket *);
155 int             atm_sock_sockaddr (struct socket *, struct sockaddr **);
156 int             atm_sock_peeraddr (struct socket *, struct sockaddr **);
157 int             atm_sock_setopt (struct socket *, struct sockopt *,
158                         Atm_pcb *);
159 int             atm_sock_getopt (struct socket *, struct sockopt *,
160                         Atm_pcb *);
161 void            atm_sock_connected (void *);
162 void            atm_sock_cleared (void *, struct t_atm_cause *);
163
164         /* atm_subr.c */
165 void            atm_initialize (void);
166 void *          atm_allocate (struct sp_info *);
167 void            atm_free (void *);
168 void            atm_release_pool (struct sp_info *);
169 void            atm_timeout (struct atm_time *, int, 
170                         void (*) (struct atm_time *) );
171 int             atm_untimeout (struct atm_time *);
172 int             atm_stack_enq (int, void (*) (int, void *, int, int), 
173                         void *, Atm_connvc *, int, int);
174 void            atm_stack_drain (void);
175 void            atm_pdu_print (KBuffer *, char *);
176
177 #endif  /* ATM_KERNEL */
178
179 #endif  /* _NETATM_ATM_VAR_H */