This source file includes following definitions.
- capi_channel
1
2
3
4
5
6
7
8
9
10
11
12
13
14 #ifndef CAPI_H
15 #define CAPI_H
16
17
18 #define REQ_CAUSE 0x01
19 #define REQ_DISPLAY 0x04
20 #define REQ_USER_TO_USER 0x08
21
22 #define AppInfoMask REQ_CAUSE|REQ_DISPLAY|REQ_USER_TO_USER
23
24
25 extern int capi_conn_req(const char * calledPN, struct sk_buff **buf);
26 extern int capi_decode_conn_conf(struct pcbit_chan * chan, struct sk_buff *skb,
27 int *complete);
28
29 extern int capi_decode_conn_ind(struct pcbit_chan * chan, struct sk_buff *skb,
30 struct callb_data *info);
31 extern int capi_conn_resp(struct pcbit_chan* chan, struct sk_buff **skb);
32
33 extern int capi_conn_active_req(struct pcbit_chan* chan, struct sk_buff **skb);
34 extern int capi_decode_conn_actv_conf(struct pcbit_chan * chan,
35 struct sk_buff *skb);
36
37 extern int capi_decode_conn_actv_ind(struct pcbit_chan * chan,
38 struct sk_buff *skb);
39 extern int capi_conn_active_resp(struct pcbit_chan* chan,
40 struct sk_buff **skb);
41
42
43 extern int capi_select_proto_req(struct pcbit_chan *chan, struct sk_buff **skb,
44 int outgoing);
45 extern int capi_decode_sel_proto_conf(struct pcbit_chan *chan,
46 struct sk_buff *skb);
47
48 extern int capi_activate_transp_req(struct pcbit_chan *chan,
49 struct sk_buff **skb);
50 extern int capi_decode_actv_trans_conf(struct pcbit_chan *chan,
51 struct sk_buff *skb);
52
53 extern int capi_tdata_req(struct pcbit_chan* chan, struct sk_buff *skb);
54 extern int capi_tdata_resp(struct pcbit_chan *chan, struct sk_buff ** skb);
55
56
57 extern int capi_disc_req(ushort callref, struct sk_buff **skb, u_char cause);
58 extern int capi_decode_disc_conf(struct pcbit_chan *chan, struct sk_buff *skb);
59
60 extern int capi_decode_disc_ind(struct pcbit_chan *chan, struct sk_buff *skb);
61 extern int capi_disc_resp(struct pcbit_chan *chan, struct sk_buff **skb);
62
63 #ifdef DEBUG
64 extern int capi_decode_debug_188(u_char *hdr, ushort hdrlen);
65 #endif
66
67 extern __inline__
68 struct pcbit_chan *
69 capi_channel(struct pcbit_dev *dev, struct sk_buff *skb)
70 {
71 ushort callref;
72
73 callref = *((ushort*) skb->data);
74 skb_pull(skb, 2);
75
76 if (dev->b1->callref == callref)
77 return dev->b1;
78 else if (dev->b2->callref == callref)
79 return dev->b2;
80
81 return NULL;
82 }
83
84 #endif
85
86
87
88
89
90