root/drivers/isdn/pcbit/edss1.h

/* [previous][next][first][last][top][bottom][index][help] */

INCLUDED FROM


   1 /*
   2  * Copyright (C) 1996 Universidade de Lisboa
   3  * 
   4  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
   5  *
   6  * This software may be used and distributed according to the terms of 
   7  * the GNU Public License, incorporated herein by reference.
   8  */
   9 
  10 /*        
  11  *        DSS.1 module definitions
  12  */
  13 
  14 #ifndef EDSS1_H
  15 #define EDSS1_H
  16 
  17 /* ISDN states */
  18 
  19 #define ST_NULL      0
  20 #define ST_CALL_INIT 1    /* Call initiated */
  21 #define ST_OVER_SEND 2    /* Overlap sending - Requests More Info 4 call */
  22 #define ST_CALL_PROC 3    /* Call Proceeding */
  23 #define ST_CALL_DELV 4
  24 #define ST_CALL_PRES 6    /* Call Present - Received CONN.IND */
  25 #define ST_CALL_RECV 7    /* Alerting sent */
  26 #define ST_CONN_REQ  8    /* Answered - waiting 4 CONN.CONF */
  27 #define ST_INCM_PROC 9
  28 #define ST_ACTIVE    10
  29 #define ST_DISC_REQ  11
  30 #define ST_DISC_IND  12
  31 #define ST_SUSP_REQ  15
  32 #define ST_RESM_REQ  17
  33 #define ST_RELS_REQ  19
  34 #define ST_OVER_RECV 25
  35 
  36 #define ST_ACTIVE_SELP 26 /* Select protocol on B-Channel */
  37 #define ST_ACTIVE_ACTV 27 /* Activate B-channel protocol  */
  38 
  39 #define MAX_STATE ST_ACTIVE_ACTV
  40 
  41 #define EV_NULL               0
  42 #define EV_USR_SETUP_REQ      1
  43 #define EV_USR_SETUP_RESP     2
  44 #define EV_USR_PROCED_REQ     3
  45 #define EV_USR_RELEASE_REQ    4
  46 #define EV_USR_REJECT_REQ     4
  47 
  48 #define EV_NET_SETUP          16
  49 #define EV_NET_CALL_PROC      17
  50 #define EV_NET_SETUP_ACK      18
  51 #define EV_NET_CONN           19
  52 #define EV_NET_CONN_ACK       20
  53 
  54 #define EV_NET_SELP_RESP      21
  55 #define EV_NET_ACTV_RESP      22
  56 
  57 #define EV_NET_DISC           23
  58 #define EV_NET_RELEASE        24
  59 #define EV_NET_RELEASE_COMP   25
  60 
  61 #define EV_TIMER              26
  62 #define EV_ERROR              32
  63 
  64 /*
  65  *  Cause values
  66  *  only the ones we use
  67  */ 
  68 
  69 #define CAUSE_NORMAL          0x10U 
  70 #define CAUSE_NOCHAN          0x22U
  71 
  72 struct callb_data {
  73         unsigned short type;
  74         union {
  75                 struct ConnInfo {
  76                         char *CalledPN;
  77                         char *CallingPN;
  78                 } setup;
  79                 unsigned short cause;
  80         } data;
  81 };
  82 
  83 struct fsm_entry {
  84         unsigned short init;
  85         unsigned short final;
  86         unsigned short event;
  87         void (*callb)(struct pcbit_dev *, struct pcbit_chan *, struct callb_data*);
  88 };
  89 
  90 struct fsm_timer_entry {
  91         unsigned short init;
  92         unsigned long timeout;          /* in seconds */
  93 };
  94 
  95 
  96 extern void pcbit_fsm_event(struct pcbit_dev *, struct pcbit_chan *,
  97                             unsigned short event, struct callb_data *);
  98 #endif
  99 
 100 
 101 

/* [previous][next][first][last][top][bottom][index][help] */