Initial import from FreeBSD RELENG_4:
[dragonfly.git] / sys / netproto / atm / sigpvc / sigpvc_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/sigpvc/sigpvc_var.h,v 1.2 1999/08/28 00:48:47 peter Exp $
27  *
28  */
29
30 /*
31  * PVC-only Signalling Manager
32  * ---------------------------
33  *
34  * Protocol control blocks
35  *
36  */
37
38 #ifndef _SIGPVC_SIGPVC_VAR_H
39 #define _SIGPVC_SIGPVC_VAR_H
40
41 #ifdef ATM_KERNEL
42 /*
43  * Structure containing state information for each SigPVC protocol instance.
44  * There will be one instance for each ATM device interface using the SigPVC
45  * signalling manager.
46  */
47 struct  sigpvc {
48         struct siginst  pv_inst;        /* Common header */
49 };
50 #define pv_next         pv_inst.si_next
51 #define pv_pif          pv_inst.si_pif
52 #define pv_addr         pv_inst.si_addr
53 #define pv_vccq         pv_inst.si_vccq
54 #define pv_state        pv_inst.si_state
55 #endif  /* ATM_KERNEL */
56
57 /*
58  * SigPVC Protocol States
59  */
60 #define SIGPVC_ACTIVE   1               /* Active */
61 #define SIGPVC_DETACH   2               /* Detach in progress */
62
63
64 #ifdef ATM_KERNEL
65 /*
66  * SigPVC Virtual Channel Connection control block.  All information regarding
67  * the state of a SigPVC controlled VCC will be recorded here.  There will be
68  * one SigPVC VCC control block for each SigPVC-controlled VCC.
69  */
70 struct sigpvc_vccb {
71         struct vccb     vcp_hdr;        /* Generic vccb */
72 };
73 #endif  /* ATM_KERNEL */
74
75 /*
76  * SigPVC VCC Signalling Protocol States
77  */
78 #define VCCS_NULL       0               /* No state */
79 #define VCCS_ACTIVE     1               /* Active */
80 #define VCCS_FREE       2               /* Waiting for user to free resources */
81
82
83 #ifdef ATM_KERNEL
84 /*
85  * Global function declarations
86  */
87         /* sigpvc_if.c */
88
89         /* sigpvc_subr.c */
90 int             sigpvc_create_pvc __P((struct sigpvc *, Atm_connvc *, int *));
91 void            sigpvc_close_vcc __P((struct vccb *));
92
93 #endif  /* ATM_KERNEL */
94
95 #endif  /* _SIGPVC_SIGPVC_VAR_H */