1 /* SPDX-License-Identifier: GPL-2.0-only */
3 * Copyright 2008 by Karsten Keil <kkeil@novell.com>
9 extern struct mISDNdevice
*get_mdevice(u_int
);
10 extern int get_mdevice_count(void);
12 /* stack status flag */
13 #define mISDN_STACK_ACTION_MASK 0x0000ffff
14 #define mISDN_STACK_COMMAND_MASK 0x000f0000
15 #define mISDN_STACK_STATUS_MASK 0xfff00000
16 /* action bits 0-15 */
17 #define mISDN_STACK_WORK 0
18 #define mISDN_STACK_SETUP 1
19 #define mISDN_STACK_CLEARING 2
20 #define mISDN_STACK_RESTART 3
21 #define mISDN_STACK_WAKEUP 4
22 #define mISDN_STACK_ABORT 15
23 /* command bits 16-19 */
24 #define mISDN_STACK_STOPPED 16
25 #define mISDN_STACK_INIT 17
26 #define mISDN_STACK_THREADSTART 18
27 /* status bits 20-31 */
28 #define mISDN_STACK_BCHANNEL 20
29 #define mISDN_STACK_ACTIVE 29
30 #define mISDN_STACK_RUNNING 30
31 #define mISDN_STACK_KILLED 31
35 #define MGR_OPT_USER 24
36 #define MGR_OPT_NETWORK 25
38 extern int connect_Bstack(struct mISDNdevice
*, struct mISDNchannel
*,
39 u_int
, struct sockaddr_mISDN
*);
40 extern int connect_layer1(struct mISDNdevice
*, struct mISDNchannel
*,
41 u_int
, struct sockaddr_mISDN
*);
42 extern int create_l2entity(struct mISDNdevice
*, struct mISDNchannel
*,
43 u_int
, struct sockaddr_mISDN
*);
45 extern int create_stack(struct mISDNdevice
*);
46 extern int create_teimanager(struct mISDNdevice
*);
47 extern void delete_teimanager(struct mISDNchannel
*);
48 extern void delete_channel(struct mISDNchannel
*);
49 extern void delete_stack(struct mISDNdevice
*);
50 extern void mISDN_initstack(u_int
*);
51 extern int misdn_sock_init(u_int
*);
52 extern void misdn_sock_cleanup(void);
53 extern void add_layer2(struct mISDNchannel
*, struct mISDNstack
*);
54 extern void __add_layer2(struct mISDNchannel
*, struct mISDNstack
*);
56 extern u_int
get_all_Bprotocols(void);
57 struct Bprotocol
*get_Bprotocol4mask(u_int
);
58 struct Bprotocol
*get_Bprotocol4id(u_int
);
60 extern int mISDN_inittimer(u_int
*);
61 extern void mISDN_timer_cleanup(void);
63 extern int l1_init(u_int
*);
64 extern void l1_cleanup(void);
65 extern int Isdnl2_Init(u_int
*);
66 extern void Isdnl2_cleanup(void);
68 extern void mISDN_init_clock(u_int
*);