aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/isdn.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/isdn.h')
-rw-r--r--include/linux/isdn.h130
1 files changed, 1 insertions, 129 deletions
diff --git a/include/linux/isdn.h b/include/linux/isdn.h
index 215c41602af8..1e9a0f2a8626 100644
--- a/include/linux/isdn.h
+++ b/include/linux/isdn.h
@@ -10,136 +10,9 @@
10 * of the GNU General Public License, incorporated herein by reference. 10 * of the GNU General Public License, incorporated herein by reference.
11 * 11 *
12 */ 12 */
13
14#ifndef __ISDN_H__ 13#ifndef __ISDN_H__
15#define __ISDN_H__ 14#define __ISDN_H__
16 15
17#include <linux/ioctl.h>
18#include <linux/tty.h>
19
20#define ISDN_MAX_DRIVERS 32
21#define ISDN_MAX_CHANNELS 64
22
23/* New ioctl-codes */
24#define IIOCNETAIF _IO('I',1)
25#define IIOCNETDIF _IO('I',2)
26#define IIOCNETSCF _IO('I',3)
27#define IIOCNETGCF _IO('I',4)
28#define IIOCNETANM _IO('I',5)
29#define IIOCNETDNM _IO('I',6)
30#define IIOCNETGNM _IO('I',7)
31#define IIOCGETSET _IO('I',8) /* no longer supported */
32#define IIOCSETSET _IO('I',9) /* no longer supported */
33#define IIOCSETVER _IO('I',10)
34#define IIOCNETHUP _IO('I',11)
35#define IIOCSETGST _IO('I',12)
36#define IIOCSETBRJ _IO('I',13)
37#define IIOCSIGPRF _IO('I',14)
38#define IIOCGETPRF _IO('I',15)
39#define IIOCSETPRF _IO('I',16)
40#define IIOCGETMAP _IO('I',17)
41#define IIOCSETMAP _IO('I',18)
42#define IIOCNETASL _IO('I',19)
43#define IIOCNETDIL _IO('I',20)
44#define IIOCGETCPS _IO('I',21)
45#define IIOCGETDVR _IO('I',22)
46#define IIOCNETLCR _IO('I',23) /* dwabc ioctl for LCR from isdnlog */
47#define IIOCNETDWRSET _IO('I',24) /* dwabc ioctl to reset abc-values to default on a net-interface */
48
49#define IIOCNETALN _IO('I',32)
50#define IIOCNETDLN _IO('I',33)
51
52#define IIOCNETGPN _IO('I',34)
53
54#define IIOCDBGVAR _IO('I',127)
55
56#define IIOCDRVCTL _IO('I',128)
57
58/* cisco hdlck device private ioctls */
59#define SIOCGKEEPPERIOD (SIOCDEVPRIVATE + 0)
60#define SIOCSKEEPPERIOD (SIOCDEVPRIVATE + 1)
61#define SIOCGDEBSERINT (SIOCDEVPRIVATE + 2)
62#define SIOCSDEBSERINT (SIOCDEVPRIVATE + 3)
63
64/* Packet encapsulations for net-interfaces */
65#define ISDN_NET_ENCAP_ETHER 0
66#define ISDN_NET_ENCAP_RAWIP 1
67#define ISDN_NET_ENCAP_IPTYP 2
68#define ISDN_NET_ENCAP_CISCOHDLC 3 /* Without SLARP and keepalive */
69#define ISDN_NET_ENCAP_SYNCPPP 4
70#define ISDN_NET_ENCAP_UIHDLC 5
71#define ISDN_NET_ENCAP_CISCOHDLCK 6 /* With SLARP and keepalive */
72#define ISDN_NET_ENCAP_X25IFACE 7 /* Documentation/networking/x25-iface.txt */
73#define ISDN_NET_ENCAP_MAX_ENCAP ISDN_NET_ENCAP_X25IFACE
74
75/* Facility which currently uses an ISDN-channel */
76#define ISDN_USAGE_NONE 0
77#define ISDN_USAGE_RAW 1
78#define ISDN_USAGE_MODEM 2
79#define ISDN_USAGE_NET 3
80#define ISDN_USAGE_VOICE 4
81#define ISDN_USAGE_FAX 5
82#define ISDN_USAGE_MASK 7 /* Mask to get plain usage */
83#define ISDN_USAGE_DISABLED 32 /* This bit is set, if channel is disabled */
84#define ISDN_USAGE_EXCLUSIVE 64 /* This bit is set, if channel is exclusive */
85#define ISDN_USAGE_OUTGOING 128 /* This bit is set, if channel is outgoing */
86
87#define ISDN_MODEM_NUMREG 24 /* Number of Modem-Registers */
88#define ISDN_LMSNLEN 255 /* Length of tty's Listen-MSN string */
89#define ISDN_CMSGLEN 50 /* Length of CONNECT-Message to add for Modem */
90
91#define ISDN_MSNLEN 32
92#define NET_DV 0x06 /* Data version for isdn_net_ioctl_cfg */
93#define TTY_DV 0x06 /* Data version for iprofd etc. */
94
95#define INF_DV 0x01 /* Data version for /dev/isdninfo */
96
97typedef struct {
98 char drvid[25];
99 unsigned long arg;
100} isdn_ioctl_struct;
101
102typedef struct {
103 char name[10];
104 char phone[ISDN_MSNLEN];
105 int outgoing;
106} isdn_net_ioctl_phone;
107
108typedef struct {
109 char name[10]; /* Name of interface */
110 char master[10]; /* Name of Master for Bundling */
111 char slave[10]; /* Name of Slave for Bundling */
112 char eaz[256]; /* EAZ/MSN */
113 char drvid[25]; /* DriverId for Bindings */
114 int onhtime; /* Hangup-Timeout */
115 int charge; /* Charge-Units */
116 int l2_proto; /* Layer-2 protocol */
117 int l3_proto; /* Layer-3 protocol */
118 int p_encap; /* Encapsulation */
119 int exclusive; /* Channel, if bound exclusive */
120 int dialmax; /* Dial Retry-Counter */
121 int slavedelay; /* Delay until slave starts up */
122 int cbdelay; /* Delay before Callback */
123 int chargehup; /* Flag: Charge-Hangup */
124 int ihup; /* Flag: Hangup-Timeout on incoming line */
125 int secure; /* Flag: Secure */
126 int callback; /* Flag: Callback */
127 int cbhup; /* Flag: Reject Call before Callback */
128 int pppbind; /* ippp device for bindings */
129 int chargeint; /* Use fixed charge interval length */
130 int triggercps; /* BogoCPS needed for triggering slave */
131 int dialtimeout; /* Dial-Timeout */
132 int dialwait; /* Time to wait after failed dial */
133 int dialmode; /* Flag: off / on / auto */
134} isdn_net_ioctl_cfg;
135
136#define ISDN_NET_DIALMODE_MASK 0xC0 /* bits for status */
137#define ISDN_NET_DM_OFF 0x00 /* this interface is stopped */
138#define ISDN_NET_DM_MANUAL 0x40 /* this interface is on (manual) */
139#define ISDN_NET_DM_AUTO 0x80 /* this interface is autodial */
140#define ISDN_NET_DIALMODE(x) ((&(x))->flags & ISDN_NET_DIALMODE_MASK)
141
142#ifdef __KERNEL__
143 16
144#include <linux/errno.h> 17#include <linux/errno.h>
145#include <linux/fs.h> 18#include <linux/fs.h>
@@ -163,6 +36,7 @@ typedef struct {
163#include <linux/skbuff.h> 36#include <linux/skbuff.h>
164#include <linux/tcp.h> 37#include <linux/tcp.h>
165#include <linux/mutex.h> 38#include <linux/mutex.h>
39#include <uapi/linux/isdn.h>
166 40
167#define ISDN_TTY_MAJOR 43 41#define ISDN_TTY_MAJOR 43
168#define ISDN_TTYAUX_MAJOR 44 42#define ISDN_TTYAUX_MAJOR 44
@@ -595,6 +469,4 @@ typedef struct isdn_devt {
595extern isdn_dev *dev; 469extern isdn_dev *dev;
596 470
597 471
598#endif /* __KERNEL__ */
599
600#endif /* __ISDN_H__ */ 472#endif /* __ISDN_H__ */